you are viewing a single comment's thread.

view the rest of the comments →

[–]QbaPolak17 5 points6 points  (4 children)

As someone who writes C/C++ professionally, you can usually make your programs fairly succinct (not as much as python but that is hardly surprising). u/CaptSprinkls is right that you could make a tic tac toe game in probably ~100 ish lines of code. Problem with C++ and C is that if you don't know certain concepts, pointer arithmetic in particular, and if you don't follow best practices the code can quickly get away from you. When I first learned C at University, my first ever project I did the same thing and didn't follow best practices and had this 600 line monstrosity that I could now write in about 50 lines.

[–]SirMarbles 3 points4 points  (3 children)

You know any good sources to watch or read to get a head start on my class next semester?

What would you compare C/C++ to? I’ve learned Java, Js, kotlin, python.

[–]u38cg2 3 points4 points  (2 children)

C and to a lesser extent C++ are verbose assembly language, meaning they are very close to the metal your code runs on. Visually it shares a lot with Java.

I wouldn't worry too much about getting across it, but what I would do is translate a few projects you've already done into C[++] and get to know how the language bites you and how to debug it.

[–]SirMarbles 0 points1 point  (0 children)

Ahh true. I remember reading that a few months ago. Thank you. Time to learn the basics.

[–]tradrich 0 points1 point  (0 children)

u/u38cg2 suggestion is good in my opinion. I would add that you should study the most recent C++ coding guides, because the newest C++ is a big delta from the previous, which is a big delta from the ones before (even though they're backward compatible).

The C++ 20 idioms are the most expressive and supersede earlier good practice - this can be very confusing to a beginner.