Quizzes
Site Language: English
Українська
English
Русский
Programming Tests
Login
Sign Up
Programming Tests
Theory
Snippets
Papers
Landing
Android
Prices
FAQ
Cosmo Story
Terms and Conditions
Privacy Policy
Cookies Policy
Send Feedback
continue label
:
Content language: English
Русский
What will be the result of the program? public class MyTest { public static void main(String[] args) { label1: for (int i = 0; i < 3; i++) { if (i == 1) continue label1; label2: System.out.print("TEST "); label3:; } } }
continue label
What happens at compilation and ruing of this piece of code? int i = 0, j = 5; tp: for (;;) { i++; for (;;) { if (i > --j) { break tp; } } System.out.println("i =" + i + ", j = " + j); }
continue label
What is the result of the program? public class B { public static void main(String[] args) { big_loop: for (int i = 0; i < 3 ; i++) { try { for (int j = 0; j < 3 ; j++) { if (i == j) continue; else if (i > j) continue big_loop; System.out.print("A"); } } finally { System.out.print("B"); } System.out.print("C"); } } }
continue label
What is the result of the following program: public class Foo { public static void main(String[] args) { for (int k = 1; k <= 10; k++) { if (k % 5 == 0) break label; System.out.print(k + " "); } label: { System.out.print("stop!"); } } }
continue label
What is the result of the following program execution? public class Bar { public static void main(String args[]) { label: for (int i = 0; i < 5; ++i) { for (int j = 0; j < 5; ++j) { if (i > 2) break label; System.out.print(j); } System.out.print(" "); } } }
continue label
What is the resut of the following code compilation and execution? public class Main { public static void main(String[] str) { outer: for (int i = 0; i < 2; i++) { for (int j = 0; j < 2; j++) { System.out.println("Hello"); continue outer; } System.out.println("outer"); } System.out.println("Good-Bye"); } }
continue label
← Prev
1
Next →
Sign Up Now
or
Subscribe for future quizzes