Java's syntax was inspired by C and C++. So are some of its high level semantics. That made it familiar to most developers when it launched. However, it took a radically different approach to everything.
C++ compiles applications to native code. Java runs in a virtual machine with a JIT.
Java is more dynamic. It focuses more on runtime behavior. C++ is more static and places more emphasis on the compiler.
Java is portable even in the binary form. C++ can be written in a portable manner but it requires some understanding of complex concepts.
Java is safe and garbage collected. In C++ memory is managed manually and you can manipulate it directly. C++ is targeted for low level code that values performance and size over ease of development. This also makes it harder to secure C++ code.
Java has an extensive portable API and 3rd party extensions. This is its crown jewel, no other language/platform comes close to it. Note that JavaScript has many 3rd party modules but many are trivial, thus inflating the numbers. Its core APIs are minuscule when compared to Java (for better and worse).
Java is standardized by a consortium of companies. But effectively Oracle is calling the shots unlike C++ which is driven by committee. This has advantages as Java can evolve fast in a responsible way (like a product). But the downside is that it's not as open as C++. Although there are many 3rd party Java virtual machines and they are open source.
Java took the philosophy of removing everything that isn't essential from the language (no operator overloading, no enums when it launched). C++ has many sophisticated language features.
On a personal note I used to code a lot in C++ and have deep dislike of the language in general. I tried to keep this as objective as possible though, but I'm happy for corrections/insights/elaborations.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Java's syntax was inspired by C and C++. So are some of its high level semantics. That made it familiar to most developers when it launched. However, it took a radically different approach to everything.
On a personal note I used to code a lot in C++ and have deep dislike of the language in general. I tried to keep this as objective as possible though, but I'm happy for corrections/insights/elaborations.