Welcome to Java MCQ (Mulitple Choice Question) series. In this post, we will see one more quiz question on Java Loops.
B. 0
C. 4
D. Compilation Error
Java
Java-Quiz
MCQ
What is the output of the following code snippet?
int i = 0;
for(i = 0 ; i < 5; i++){
}
System.out.println(i);
A. 5B. 0
C. 4
D. Compilation Error
Answer:
A. 5
Comments
Post a Comment