answersLogoWhite

0

Classes are the basic unit of code in Java, whereas the basic unit of code in C++ are functions.

All objects in Java descend from a common class (Object), which allows more generic code. While this can also be (manually) implemented within C++, generic programming is best achieved using templates and concepts.

All methods in Java (including destructors) are virtual by default. In C++, methods must be explicitly declared virtual if they are expected to be overridden, or explicitly declared final if they must not be overridden.

Java does not permit operator overloading, thus we cannot operate upon objects as intuitively as we can in C++.

User Avatar

Wiki User

7y ago

What else can I help you with?

Related Questions

What is the difference between c plus plus and java programming?

Java doesn't have pointers. C++ has pointers.


Difference between java and C plus plus?

java is an advanced object oriented programming language than c++


What are the main differences between Java and C plus plus?

the difference is that c plus is better because you get big grades


Difference between procedure and function in C or C plus plus or Java language?

In C there are functions only, In Java methodsonly (static methods as well), in C++ both.


Major difference between c and java?

Java is object oriented, C is not...


What is the difference between cc plus plus and java?

C is a procedure oriented language ,Where C++ & java are object oriented language.But java is platform independent.So generally C is called POP.C++ is called OOP.But java is OOP , which is platform independent.If java does not support primitive data type then it is called as pure object oriented language.


Is Java better than c plus plus?

It is a different tool with difference strengths and weaknesses.


What is difference between exception handling in C and Java?

Easy: there is no exception-handling in C.


Which is easier 'C plus plus' or 'Java'?

Java is considerably easier than C++.


Which is more popular c plus plus or java?

Java


What is the difference between pointers in c and c plus plus?

Nothing.


Is it necessary for you to learn c and c plus plus before you go for java?

No. You can learn Java first if you want. However, from a language perspective, C++ and Java are nearly identical1, and C is the predecessor of C++, so some people feel that the proper sequence is C, then C++, then Java. It is entirely up to you. ----------------------------------------------------------------------------- 1Nearly identical, that is, from a language perspective only. The environment and libraries are vastly different between C++ and Java.