Java features which makes the java most popular language..

The java is a most popular programming language platform present in the world today. More than 30 Millions devices which run on java technology. Following are the most important properties of java which have made it no #1 choice for programmer around the world.


1)Platform Independent:- Before we say and can understand meaning of the word platform, In programming the word platform means the environment In which a programs runs in simple words it is the combination of operating system and central processing unit. So window 10+ core i5 is one platform while Linux + core i7 is another platform. Now being platform independent means that a programmer which is compiled on window platform can directly executed on Linux platform without re-writing or re-compiling and java has speech up using it’s important component called 1. Bytecode 2. JVM.
Whenever we compiled a java program the compiler never generates machine code rather the java compiler converts our program from source code to bytecode.
The bytecode is an intermediate code which is neither understandable to humans nor understandable to special software called as JVM (Java virtual machine).
The JVM converts these bytecode instruction according to the underline platform machine instruction set and run set.
Thus whenever a JVM is present there we can execute any java application without recompiling or rewriting it. This makes java a platform independent language and truly justifies it’s punch line called ‘WORA’.
WORAstands for write once and run anywhere.



Java-Platform-Independent
Java Platform Independent



2)Automatic memory management :- Java has very good management features.

For example:-
In java program a programmer only has two allocate memory and use it but it’s de-allocation is not programmer’s re-possibility. This re-possibility is handled by the JVM. So that programmer can concentrate more of his logic of program rather than managing a memory.


3)Robust (Fault tolerant):- Java has some very strict rules which every programmer must followed and if a programmer breaks these rules then java terminates the program by generates Exception (run time error)
For example:-
            In java, we are not allowed to cross boundaries of an array and if we do that then java kills our program by generates exception, thus we can say that java is a robust and fault tolerant language.


4)Secure:-  Java is no. 1 language in terms of security.
For example:-

  •             Java does not supports pointers because it does not want to allow programmers to directly interact with hardware. Thus in terms of security java is much more powerful then c and c++ language.


5)Simple:- Java has borrowed it’s maximum syntax form languages like c and c++. So topics like operator, data types, control statement and loop etc. Have exactly same syntax like it is in c language. So if a person has basic knowledge of c for her/him java is very simple to learn.


6)Object oriented:- Java strictly  follow object oriented programming and forces programmer to use these principle in all the program they write.
For example:-
It compulsory to make use of class in every program which we design in java this is called as encapsulation and is a important pillar of object oriented programming.
            Similarly other object oriented programming principle like Inheritance, polymorphism, abstraction etc. are also present in java.


7) Multi-threading:- The word multi-threading means parallel execution. In other word we can say that if we are able to execute multiple function of the same program simultaneously then it is called multi-threading.

For example :-

Consider a music player. If we closely observed we will find that there are many activities which they take place simultaneously.
1)    Playing of a song.
2)    Running of sliders to show how much song has been played.
3)    Allowing the user to change volume and other setting during song play.
4)    Running of a timer to show the time.


All these activities take place together and this is called multi-threading.

Java has very good built-in support for multi-threading application. So music player , chatting app as well as games can be easily develop in java.





Comments

Post a Comment