Commit | Line | Data |
---|---|---|
fc3673c1 JB |
1 | /****************************************************************************** |
2 | * Compilation: javac HelloWorld.java | |
3 | * Execution: java HelloWorld | |
4 | * | |
5 | * Prints "Hello, World". By tradition, this is everyone's first program. | |
6 | * | |
7 | * % java HelloWorld | |
8 | * Hello, World | |
9 | * | |
10 | * These 17 lines of text are comments. They are not part of the program; | |
11 | * they serve to remind us about its properties. The first two lines tell | |
12 | * us what to type to compile and test the program. The next line describes | |
13 | * the purpose of the program. The next few lines give a sample execution | |
14 | * of the program and the resulting output. We will always include such | |
15 | * lines in our programs and encourage you to do the same. | |
16 | * | |
17 | ******************************************************************************/ | |
18 | ||
19 | public class HelloWorld { | |
20 | ||
21 | public static void main(String[] args) { | |
22 | // Prints "Hello, World" to the terminal window. | |
23 | System.out.println("Hello, World"); | |
24 | } | |
25 | ||
26 | } |