+ 5

Why Java is platform independent language?

to run Java codes there must be JVM in the system..then how it is platform independent...?

11th Feb 2018, 8:51 AM
Chaudhary Imran Sohrab
Chaudhary Imran Sohrab - avatar
7 Respuestas
11th Feb 2018, 9:55 AM
Gaurav Agrawal
Gaurav Agrawal - avatar
+ 6
The byte code made by JAVA remains the same and is converted to source code as per platform. Also known WORA (Write Once, Read Anywhere).
11th Feb 2018, 9:30 AM
Karan Kumar
Karan Kumar - avatar
+ 4
good answered @ Jonas Schroter...but I also want anymore reasons?
11th Feb 2018, 9:06 AM
Chaudhary Imran Sohrab
Chaudhary Imran Sohrab - avatar
+ 3
It's because the byte code generated by compiling the source code of any Java program works the same on any JVM installed machine regardless of the OS of the machine. Therefore we don't have to worry about the OS. If there is JVM installed in the machine, your code will run and give desired output.
9th Mar 2018, 5:39 AM
Meghna Bisht
+ 2
Cause you can install the JVM on different platforms, the compiler stays the same.
11th Feb 2018, 8:55 AM
Jonas Schröter
Jonas Schröter - avatar
+ 2
java is platform independent language..as in c language the run of the program is depends on the compiler...suppose if u have windows os then compiler type is different...same for linux....etc.....but in java its doesnot matter what the type of the operating system is....the main fact of java is write the code once and run in any kind of os[maybe windows ,may be linux..]so thatswhy java is platform independent
11th Feb 2018, 3:00 PM
Debadi Prasanna Gongopadhyay
+ 1
Java is an interpreted language, not a compiled ones. The compiling process depends on the OS, but interpretation not
11th Feb 2018, 11:20 AM
Leonardo Medai Cossutta
Leonardo Medai Cossutta - avatar