public class NewCase { public static void main(String[] args) { int n = Integer.parseInt(args[0]); switch(n) //you can switch on integral types //any of the four integer types //strings //chars //enums (later) { case 0 -> System.out.println("You entered a zero."); case 1 -> System.out.println("You entered a one."); case 2 -> System.out.println("You entered a two."); default -> System.out.println("Having a default is optional"); } } }