when there is a need of jvm then how we can say that java
is a platform independent language?
Answer Posted / vatsal doshi
JVM is actually a virtual machine, which operates at one level of abstraction above the actual platform.
Platform = OS + Underlying Hardware
Now, Java compiled code(byte code) is targetted to run on JVM, independent of underlying actual platform.
So, Java code written on windows can be directly run on linux/mac/solaris, without recompilation, provided JVM is installed in the target machine.
We have different implementations of JVM for different platforms. The advantage is that though JVM is platform dependent, but the compiled code now becomes platform independent.
| Is This Answer Correct ? | 17 Yes | 0 No |
Post New Answer View All Answers
Does java allow default arguments?
What does sprintf mean?
How to instantiate member inner class?
How do you check whether the list is empty or not in java?
What is the applet security manager, and what does it provide?
What if I write static public void instead of public static void in java?
How a variable is stored in memory?
What is meant by object oriented programming – oop?
What is the difference between static and global variables and also define what are volatile variables?
Give example to differentiate between call by value and call by reference.
Is null a value?
How do you square a number in java?
How do you bind variables?
What is the implementation of destroy method in java. Is it native or java code?
Is linkedlist thread safe in java?