How Java runs
(Source → Bytecode → JVM)
- Write code in a
.javafile. - Compile with
javacto generate.classbytecode. - Run with
javawhich starts the JVM. - JVM interprets and JIT-compiles code for performance.
(Source → Bytecode → JVM)
.java file.javac to generate .class bytecode.java which starts the JVM.