What would be the result of the following code? public class Quest { int i=0; public static void main(String argv[]) { } Quest() { top: while(i <2) { System.out.println(i); i++; continue top; } } }
Correct Answer:
The code will not compile as a target label cannot appear before the corresponding continue or break statement.
Explanation:
Note: This Question is unanswered, help us to find answer for this one
More Java MCQ Questions