In this Post you know the Difference Between C++ and Java and also know about the Introduction of C++ and JAVA.
What is C++ Introduction
C++ Introduction:– C++ is an object-oriented programming language and it is also known as a structural programming language. It was developed by Bjarne Stroustrup at AT & T’s Bell Laboratory(USA) in 1979.
C++ provides so many features such as Array, Structure, class and object, constructure and destructure, inheritance, polymorphism, containership, encapsulation, sorting, queue, and linked list.
What is Java Introduction
Java Introduction:- Java is a class-based high-level object-oriented programming language. It is invented by James Gosling and Sun microsystems in 1991. Ha had a single motto while creating the language, it was “Write Once, Run Anywhere”.
This means that the code would have to be written only once, but it could be used anywhere. They named this language “Oak” because of the Oaktree Gosling’s office. Later, it was named “Green”
Java is a high-level programming language that is easy to learn and understand. Java is popularly used in the console, graphical user interface and the mobile applications, web, game development and also make embedded systems.
Apart from these java is also to used software for devices. It is used not only in computers and mobiles but even in electronic devices like televisions, washing machines, air conditioners, and so on. Online forms, banking, and shopping are possible because of Java.
Difference between C++ and Java
|1||C++ is a platform dependent language.||Java is a platform-independent language.|
|2||C++ also called semi-oops language.||Java is called the complete oops language.|
|3||C++ support multiple inheritance.||Java doesn’t support multiple inheritances.|
|4||C++ supports constructor and destructure.||Java supports only destructure.|
|5||C++ supports three access specifiers like-(public, protected, private).||Java supports access modifiers like- public, protected, private, and default.|
|6||C++ supports(::) operator and operator overloading.||Java doesn’t support(::) as well as operator overloading.|
|7||C++ support pointers.||Java doesn’t support pointers.|
|8||C++ support pre-processor.||Java doesn’t support pre-processor.|
|9||In C++, there are three types of loops.||But in java supports four types of loops.|
|10||C++ has compiled language.||It is compiled and interpreted language.|
|11||C++ includes structure and union.||Java does not include structure and union.|
|12||It requires explicit memory management.||Java includes automatic garbage collection.|
|12||There is header file in C++.||There is no header file.|
I hope you like today’s article, Difference between C++ and Java. If you have any queries or suggestions ask us in the comment below.
You can also join us on social media, share this article with your friends or families, and don’t forget to subscribe it.
STAY HAPPY STAY HEALTHY