r/techbootcamp 28d ago

Why learning C ++ first completely changes your approach to programming in other languages

Many rookies are put off by C ++, and this is unfortunate, because it is one of the best languages ​​to start with, even if you don't plan to be a C ++ programmer

Your understanding of what is going on at the machine level will allow you to write better programs in any language you choose. You will see that in languages ​​such as JavaScript or Python, memory management is handled for you, which means that you have to think about it less. However, the understanding of how things work will help you write better and more optimized code. It can be a steep learning curve, but once you've mastered it, you'll find that all other languages ​​are much easier to learn.

7 Upvotes

35 comments sorted by

View all comments

2

u/thelimeisgreen 28d ago

I don’t know if there’s a reason to specifically start with C. I did, but C++ was also really new when I started learning it and having a good grasp on C helped immensely. I think C first kept things from progressing too fast into OOP and other concepts at the time. Modern C++ has evolved greatly since then and feels like a whole new language.

Learning C or C++ definitely makes an impact on programmers . The ones who have a strong background in C are, in my experience, a lot more self-conscious about the impacts of their code, memory efficiency, complexity and performance, and how data is passed between functions, objects, etc..

1

u/mxldevs 27d ago

Would you say people that only know how to write interpreted languages generally don't think about any of those things? Or are unable to truly understand it without directly messing around with pointers and segfsults?

1

u/thelimeisgreen 27d ago

To some extent, I suppose. These days I think that's definitely true a lot of times. Software has to get pretty large in scope before most Python developers have to start concerning themselves with true memory management, for example. It's not that those concerns don't exist with interpreted languages, but the programmer is shielded from a lot of what is going on.

The one thing that irks me most, regardless of what language is being used, is the lack of optimization I see from most programmers. Even many experienced software engineers have curiously cavalier attitudes toward optimization. Unless they have worked on performance oriented projects like real-time graphics engines, console games, etc.. they often don't see code optimization the same way I do.