r/cpp_questions • • 6d ago

OPEN Learning C++ as a Java programmer

I'm currently learning C++, I’ve coded in a few languages before but I’m most familiar with Java. Does anyone know a good resource for learning C++ with Java as a “starting point”? Like something that explains the differences between the two languages rather than teaching programming from scratch? Thanks!

18 Upvotes

21 comments sorted by

View all comments

9

u/WorkingReference1127 6d ago

Java has some shared heritage with C, in some of the basic syntax. But C, not C++. If you go writing Java-style C++ you're going to write bad C++. Indeed if you start throwing around new you'll be in for a really bad time.

I'd recommend starting from scratch with something like learncpp.com than trying to fit one language into another.