Java is simple programming language and most of the concepts are derived from C an C++ and complex topics(pointers) of c and c++ have been eliminated in java.
Unlike C++, Java is purely object-oriented program language.Java program uses object an classes.
C++ is also object oriented program language but not purely object oriented,because without using classes and objects we can write the C++ programs.
Class: A class represents common behavior of objects.A class is a model for creating the object.A class also contains variables and methods.A class doesn’t exist physically.
Java programs will not crash easily because of it’s memory management and exception handling mechanism.In C++, programmer is responsible for allocating and de-allocating memory.In Java the memory is allocated by JVM.
Exception is nothing but run time error.Even though if we have any exceptions in the program we can run the Java program without crash
Java enables the construction of virus free and tamper tree programs.
Java programs give same result on all machines, because Java is a platform independent.
Information is distributed on various computers on a network.Using Java we can write programs which capture information and distribute it to clients.
- Architectural Neutral
Java byte code is system independent and we can run byte code on any machine with any operating system and processor.
Java compilers give byte code and this byte code will be downloaded and executed by interpreter.
- Multi Threaded
We can create a process in Java called threads.This is especial future in java for developing server side applications.
- High Performance
Along with interpreter,there is a JIT compiler which enhances the speed of execution.
Using Java,we can develop programs which can dynamically interact with the user on the internet.
Object An object is a instance of a class.An object contains variable and methods.An object exist physically.