schizo 2022 年 1 月 5 日 下午 9:12
c or c++
I am currently strong in java and I want to improve my academic career. So i will be signing up for one of the courses at local colleges for camp in the summer. one of the classes i will be hopefully be taking is an intro to the c language, and I heard that c and c++ is very similar and practically the same in terms of basic syntax. Now i want to learn c++ because of the more versatility i can work with yet I also want to learn c because i want to be more than prepared when i take the college class (it will be on my transcript so it is important for me)
What are your thoughts? C or c++ in my situation?
Imo i want to focus on just one language at a time as i don’t have a lot of time to focus on multiple thingd
最後修改者:schizo; 2022 年 1 月 5 日 下午 9:15
< >
目前顯示第 1-15 則留言,共 23
Omega 2022 年 1 月 5 日 下午 9:35 
Rust. :steammocking:


C++ tends to be easier as it is a bit more abstract than C.

Yet C is in its design much more minimalist and simplistic. It is a 50 year old programming language build around the limitations of the time and even modern versions of it follow the same minimalist philosophy.

C is significantly more popular, you are more likely to encounter it in existing software projects.

C tends to be faster and produce smaller binaries.
最後修改者:Omega; 2022 年 1 月 5 日 下午 9:36
schizo 2022 年 1 月 5 日 下午 10:11 
引用自 Omega
Rust. :steammocking:


C++ tends to be easier as it is a bit more abstract than C.

Yet C is in its design much more minimalist and simplistic. It is a 50 year old programming language build around the limitations of the time and even modern versions of it follow the same minimalist philosophy.

C is significantly more popular, you are more likely to encounter it in existing software projects.

C tends to be faster and produce smaller binaries.
That’s a pretty good point that C is faster and simplistic but i like to create things like “bots” in java where it would use rgb pixels and click on certain parts of the screen and make key pressed programmatically. Can this still be achieved using C?
(yeah checking for rgb pixels on the screen with java is just too slow imo)
最後修改者:schizo; 2022 年 1 月 5 日 下午 10:11
schizo 2022 年 1 月 5 日 下午 10:14 
引用自 schizo
引用自 Omega
Rust. :steammocking:


C++ tends to be easier as it is a bit more abstract than C.

Yet C is in its design much more minimalist and simplistic. It is a 50 year old programming language build around the limitations of the time and even modern versions of it follow the same minimalist philosophy.

C is significantly more popular, you are more likely to encounter it in existing software projects.

C tends to be faster and produce smaller binaries.
That’s a pretty good point that C is faster and simplistic but i like to create things like “bots” in java where it would use rgb pixels and click on certain parts of the screen and make key pressed programmatically. Can this still be achieved using C?
(yeah checking for rgb pixels on the screen with java is just too slow imo, simple nested for loop still seems wacky on a 1440p monitor)
Omega 2022 年 1 月 5 日 下午 10:46 
引用自 schizo
引用自 Omega
Rust. :steammocking:


C++ tends to be easier as it is a bit more abstract than C.

Yet C is in its design much more minimalist and simplistic. It is a 50 year old programming language build around the limitations of the time and even modern versions of it follow the same minimalist philosophy.

C is significantly more popular, you are more likely to encounter it in existing software projects.

C tends to be faster and produce smaller binaries.
That’s a pretty good point that C is faster and simplistic but i like to create things like “bots” in java where it would use rgb pixels and click on certain parts of the screen and make key pressed programmatically. Can this still be achieved using C?
(yeah checking for rgb pixels on the screen with java is just too slow imo)
Anything can be done. But it will be significantly more work, you will first have to explain in C/C++ to your program how to actually do these things.

It is not as nice and abstract as "Move mouse to position X/Y and click" like in other high-level languages such as Java and Python. You will have to manually explain it where to get this data, how to process it and how to communicate with the relevant components of your operating system when performing these advanced tasks.

Of course there are libraries which have most of this code written already for you.


For bots you really should stick to Java or Python.
最後修改者:Omega; 2022 年 1 月 5 日 下午 10:49
76561198343548661 2022 年 1 月 5 日 下午 11:33 
C++ is better than C . But C++ is just an improvement of C . The use of classes is very powerful tool in the hands of the developer but when the speed is important , you may do the job in pure C .

in C we have structures but in C++ we have clesses as well - very powerful in regards to object oriented programming .
最後修改者:smallcat; 2022 年 1 月 5 日 下午 11:37
Der tüddelige Fußgänger 2022 年 1 月 5 日 下午 11:34 
Of course holy C
What else
Duh?
Omega 2022 年 1 月 5 日 下午 11:38 
引用自 littlecat20160
C++ is better than C . But C++ is just an improvement of C . The use of classes is very powerful tool in the hands of the developer but when the speed is important , you may do the job in pure C .
C++ is not an improved version of C but a completely different C-inspired language.

Which one is better will depend on the use case and personal preference.
76561198343548661 2022 年 1 月 5 日 下午 11:40 
Omega , you re absolutely wrong . i am a C/C++ developer and know a lot .

In C++ , classes are introduced but we can use everything from the pure C , including structures .
最後修改者:smallcat; 2022 年 1 月 5 日 下午 11:42
[N]ebsun 2022 年 1 月 6 日 上午 12:16 
C++
why limit yourself to just C

C++ is more widely used
easier to find help with it (since you can google C++ easier than C)
does everything that C can do

If you already use Java, C++ is pretty easy to pick up (at least the core syntax)
_I_ 2022 年 1 月 6 日 上午 12:53 
c can do a few things that c++ cant
but c++ can do so much more than c

if you learn c++ you only need to learn the differences and limitations to each
DevaVictrix 2022 年 1 月 6 日 上午 3:16 
I guess if you’re doing it at college and hope for a career… both, and as many others as you can. I’d go c++ though because of classes.
nullable 2022 年 1 月 6 日 上午 7:30 
引用自 Mind
Pure C is good to learn if you're getting into C++. It's good to distinguish between the two, since a lot of people mix them up. They taught C at my college using Unix systems (very text based), as well as assembly. C++ today can be very bloated, so you have to know what and what not to use to keep it fast, especially in regards to containers.

They say only a madman would use all of C++. They also say only a madman would use C++. -Douglas Crockford
最後修改者:nullable; 2022 年 1 月 6 日 上午 8:08
tonimark 2022 年 1 月 6 日 上午 7:46 
c++ its just the next generation of c its designed to be similar to c but more user friendly and features to programmers,c as they says its faster because its older with less user-friendly commands but translate more directly to computer input also a note here java is a upgraded versions of c++
this article can help: https://en.wikipedia.org/wiki/Compatibility_of_C_and_C%2B%2B
最後修改者:tonimark; 2022 年 1 月 6 日 上午 7:48
A&A 2022 年 1 月 6 日 下午 5:10 
C++ have more libraries.
C should be faster than C++ but in some situations can be the opposite.
_I_ 2022 年 1 月 6 日 下午 6:13 
c is more for hardware level programming, ex. direct memory access


win x64 has all the 32bit libraries and can run almost anything from win32
< >
目前顯示第 1-15 則留言,共 23
每頁顯示: 1530 50

張貼日期: 2022 年 1 月 5 日 下午 9:12
回覆: 23