Compiling and Running:
. Java source file 👉 Java 👉 .class ( Byte code )
👇 Output 👈 java (JDK)
The process of compiling and running a Java program involves two main steps:
1. Compilation
Java source code (written in .java files) must be compiled into bytecode (.class files) before it can be executed by the Java Virtual Machine (JVM).
Steps:
-
Write Java code in a text editor or an Integrated Development Environment (IDE) and save it as a
.javafile. -
Compile the code using the
java.c(Java Compiler) command.

Comments
Post a Comment