Beginning Java/First Program

From Wikibooks, open books for an open world
Jump to: navigation, search

HelloWorld.java[edit]

Below is the example of simple java program that writes "Hello, World!":

Crystal Clear app terminal.png Code:

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

Crystal Clear app kscreensaver.png Output:

Hello, World!

Main Method[edit]