How to write First program In Java and Compile through Command Prompt and Run it || Daily Tech News

Hey Guys...

Today I Discuss how to create or write programs in java and compile through command prompt and also run it.

Follow to writing the first program in java.
Open any editor and write code after that save the file extension with java like that -
The file name is Hello save the type Hello.java

Program Code Here:- 

class Hello{
    public static  void main(String[] args)
    {
    System.out.print("Hello World !!");
    }
}



compile Here:-
How to write First program In Java and Compile through Command Prompt and Run it || Daily Tech News

After Compiling a New File Add on the Same Directory that is called Class file Hello.Class

Run Here:-
How to write First program In Java and Compile through Command Prompt and Run it || Daily Tech News

Thanks !!!!


Post a Comment

2 Comments

thanks for your suggestion and improving quality of the content