What is the difference between C++ & Java?

Answer Posted / afreen

Differences between c++ and java are as follows:-
..c++ has header file #include<iostream.h> whereas java has import java.io.*;
..c++ uses clrscr() and getch(), java do not.
..c++ supports destructor, whereas java do not.
..complilation and running program differs in c++ and java.
..java is platform independent and machine independent, whereas c++ is not.
..In c++,the entire program is written in one class itself whereas java can have multiple classes.

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is == mean?

553


What are basic data types?

563


What is java util hashmap?

522


What are identifiers in java?

578


What does void * mean?

537






Can a final variable be null?

554


Can a constructor be protected?

536


Can we override singleton class?

540


Which is easier netbeans or eclipse?

614


What is identifier with example?

580


What do you mean by inner class in java?

568


Can we create a class inside a class in java?

550


What are the basic concepts of OOPS in java?

570


What is arrays aslist in java?

523


How do you convert an int to a double in java?

596