Auswertung

Language: German
Subject: Sonstiges > Sonstiges
School grade: Germany Germany

Auswertung

Gib für die folgenden print-Statements an, was sie ausgeben, bzw gib "Exception" oder "Error" ein, falls eine Exception geworfen wird / ein Error vortritt. Alle Variablen sind int Variablen ohne Over-/Underflow.

System.out.println((6 + 3) / 2 - (5 % 2) + "Java" + 3 * 2 + 1);

System.out.println("Hello" + (4 * 3 % 5) + 2 * 2 + "World" + (5 - 3) * 2);

System.out.println(8 + 7 % 3 + "8" + (4 / 2) * 3 - 1);

System.out.println(2 * (7 / 3) + "8" + (4 % 2 - 1) + 3);

System.out.println(6 * 2 + "9" + (1 * 2) / (2 / 2) + 7 % 2);

System.out.println("Programming" + (6 % (4 + 2)) * 4 + (6 / 2) + "Rocks");

System.out.println((9 / 2) + "3" + 1 * (5 + 2) + 7 % (2 - 1));

System.out.println(8 + 4 + "5" + (2 * 2) - (1 + 1));

System.out.println("Java" + ((8 / 2) * 3) + 5 + "Rocks" + (4 % 3 - 1));

System.out.println(7 - (2 * (3 + 2)) + "8" + (2 * (3 / 2)) / 2);

System.out.println(((6 + 3) / 2 - (5 % 2)) + "Java" + (3 * 2) + 1);

System.out.println("Hello" + ((4 * 3) % 5) + 2 * 2 + "World" + (5 - 3) * 2);

System.out.println(8 + (7 % 3) + "8" + ((4 / 2) * 3) - 1);

System.out.println(2 * (((7 / 3) + 2)) + "8" + (4 % (2 - 1)) + 3);

System.out.println((6 * 2) + "9" + (1 * 2) / (2 / 2) + (7 % 2));

System.out.println("Programming" + (((6 % (4 + 2)) * 4) + (6 / 2)) + "Rocks");

System.out.println((((9 / 2) + "3" + 1) * (5 + (2 / (2 - 1)))) - 1);

System.out.println((8 + 4 + "5" + ((2 * 2) - (1 + 1))) + (7 % 2));

System.out.println("Java" + (((8 / 2) * 3) + 5) + "Rocks" + ((4 % 3) - 1));

System.out.println((7 - (2 * 3 + 2)) + "8" + ((2 * (3 / 2)) / 2) + 1);

System.out.println((((6 + 3) / 2) - (5 % 2)) + "Java" + (3 * 2) + (1 + 1));

System.out.println("Hello" + (((4 * 3) % 5) + 2 * 2) + "World" + (((5 - 3) * 2)));

System.out.println(8 + (7 % 3) + "8" + ((((4 / 2) * 3) - 1) / 2));

System.out.println((2 * (((7 / 3) + 2)) + "8" + (4 % (2 - 1)) + 3) - 1);

System.out.println((((6 * 2) + "9" + (1 * 2)) / (2 / (2 - 1)) + (7 % 2));

System.out.println(("Programming" + ((((6 % (4 + 2)) * 4) + (6 / 2))) + "Rocks") + 2);

System.out.println(((((9 / 2) + "3" + 1) * (5 + (2 / (2 - 1)))) - 1) * 3);

System.out.println(((8 + 4 + "5" + ((2 * 2) - (1 + 1))) + (7 % 2)) / 2);

System.out.println(("Java" + (((8 / 2) * 3) + 5) + "Rocks" + ((4 % 3) - 1)) + 1);

System.out.println(((7 - (2 * 3 + 2)) + "8" + ((2 * (3 / 2)) / 2) + 1) * 2);

System.out.println((-19) % 3)

System.out.println((3/0 == 0) && true);

System.out.println(false && (3/0 == 0));

System.out.println(true || (3/0 == 0));