Several lines, in order
A program's instructions are called statements. Inside main they run from top to bottom, one after another, and each System.out.println prints one line. Statements like these end with a semicolon ;, much like a sentence ends with a full stop. (Later modules show statements that hold other statements in braces instead, such as if and loops.)
public class Main {
public static void main(String[] args) {
System.out.println("3");
System.out.println("2");
System.out.println("1");
System.out.println("Liftoff!");
}
}
3
2
1
Liftoff!Swap two of the lines and the countdown is in the wrong order: the computer does exactly what the statements say, in the order they are written.
The output has to match exactly
The checks on this site compare what your program prints with the expected output, character by character. Liftoff! and liftoff! are different, and so are Hello, world and Hello,world. The only things ignored are spaces at the very end of a line and empty lines at the very end of the output. Real programs are held to the same standard: another program reading your output won't guess what you meant.
Less typing
System.out.println is long to type, especially on a phone. On a touch screen, the row of keys under the editor has a sout key that types System.out.println(); for you, with the cursor inside the parentheses. Many Java editors have the same shortcut: type sout and press Tab.