1//This is for printing in columns
2System.out.println("Hello World!");
3
4//This is for printing in rows
5System.out.print("Hello World");
6
7//When im using the double slash its to comment, also remember that you dont need to type Hello World! you can type everything you want
8//By the way, you can also do:
9
10int a = 1;
11System.out.println(a);
12
13//the result of this is "1" because a is equal to 1 so the programm whill get the data stored in "a" and print it, remember that you can also use "print" instead of "println" it works whit "vairables" too! (oh, the: int a = 1; is a variable)
1public class writingInTheConsole {
2 public static void main(String[] args) {
3System.out.println("Hello Java! I made Minecraft: Java Edition!");
4 }
5}
1public class ConsoleTest {
2 public static void main(String[] args) {
3 System.out.println("Console is: " + System.console());
4 }
5}