Internal Details of Hello Java Program
In the previous page, we have learnt about the first program, how to compile and run the first java program. Here, we are going to learn, what happens while compiling and running the java program. Moreover, we will see some question based on the first program.
What happens at compile time?
At compile time, java file is compiled by Java Compiler (It does not interact with OS) and converts the java code into bytecode.
What happens at runtime?
At runtime, following steps are performed:
Q) Can you save a java source file by other name than the class name?
Q) Can you have multiple classes in a java source file?