What does the Java Virtual Machine actually run?
Bytecode in class files, not Java source code.
- Bytecode in class files ✔
- Java source code
- Native code for each CPU
Why: Java source is compiled into class files containing JVM bytecode. The JVM knows nothing about the Java language itself, only that binary format. That is why other languages like Kotlin can run on the JVM too.
Huh, didn't know that: The class file format is hardware and operating system independent, which is the heart of write once, run anywhere.
Why do Java developers wear glasses? Because they don't C#.
References
Answer: Bytecode in class files. Java source is compiled into class files containing JVM bytecode. The JVM knows nothing about the Java language itself, only that binary format. That is why other languages like Kotlin can run on the JVM too.
- The Java Virtual Machine Specification, Java SE 21: Introduction docs.oracle.com/javase/specs/jvms/se21/html/jvms-1.html
The Java Virtual Machine knows nothing of the Java programming language, only of a particular binary format, the class file format.
Checked 2026-10-10.
Think this answer is wrong? Tap "Challenge this answer" on the card in the game and tell us why.
More stuff everyone should know
That's stuff everyone should know.