Sail E0 Webinar
Question
1. public class Test{
2. public static void main(String [] args){
3. int x = 0;
4. // insert code here
5. do{ } while(x++ < y);
6. System.out.println(x);
7. }
8. }
Which option, inserted at line 4, produces the output 12?
Options:
A .  int y = x;
B .  int y = 10;
C .  int y = 11;
D .  int y = 12;
E .  None of the above will allow compilation to succeed.
Answer: Option C

Submit Your Solution Below and Earn Points !
Next Question

Submit Solution

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

Latest Videos

Latest Test Papers