Java Code to Print Hello World

In this article we are going to write ‘Hello World’ program in java. This is a beginner level program in Java.

package gangforcode;

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

Hello World Java Output –

Hello World Java

This is the simplest java code with the main class and a single print statement. That’s why we know the hello world program as the first program in the journey of learning coding.


Similar Java Program tutorials –

data types in java –
identifiers in java –
keywords in java –

5 thoughts on “Java Code to Print Hello World”

Leave a Comment