What is the result?

Given:
public class MyFor {
public static void main(String[] args) {
for (int ii = 0; ii < 4; ii++) {
System.out.println("ii = "+ ii);
ii = ii +1;
}
}
}
What is the result?
A. ii = 0
ii = 2
B. ii = 0
ii = 1
ii = 2
ii = 3
C. ii =
D. Compilation fails.

Download Printable PDF. VALID exam to help you PASS.

Leave a Reply

Your email address will not be published. Required fields are marked *


The reCAPTCHA verification period has expired. Please reload the page.