Multiple Choice
Which of the following loops executes exactly 10 times?
A) for (int i = 0; i <= 10; i++) { }
B) int i = 0;
Boolean found = false;
Do
{
I++;
If (i % 10 == 0)
{
Found = true;
}
}
While (i < 10 && !found) ;
C) int i = 0;
While (i <= 10)
{
I++;
}
D) for (int i = 1; i <= 10; i++)
Correct Answer:

Verified
Correct Answer:
Verified
Related Questions
Q118: What will be the final output of
Q119: Which of the following loop(s) should be
Q120: How many times will the output line
Q121: What is the output of the code
Q122: What is the output of the code
Q123: Which loop does not check a condition
Q124: How many times does the following code
Q125: What does the following code do?<br>Int sum
Q126: Which of the loop(s) test the condition
Q128: Assume the following variable has been declared