Introduction
What you'll do in Java?
You type a source code file, compile it using the javac compiler, then run the compiled bytecode on a Java virtual machine.
- Source: Type your source code. Save as filename.java.
- Compiler: Compile the filename.java file by running javac filename.java. If you don't have errors, you'll get a second file named filename.class.
- Ouput: Compiled code: filename.class. The compiled-generated filename.class file is made up of bytecodes.
- Vitual Machines: Run the program by starting the Java Virtual Machine (JVM) with the filename.class. The JVM translates the bytecodes into something the underlying platform understands, and runs your program.