How many times will this code print out the line "Test":

for (int k = 1; k < 10; k++) {
    if (k % 2 == 1)
    continue;
    System.out.println("Test");
}
Explanation
Will be printed 4 times - once for every even number less than - for 2, 4, 6, 8.
Java
Java Quiz
Start Quiz

or Read more about Java Quiz

Follow CodeGalaxy

Mobile Beta

Get it on Google Play
Send Feedback