Chapter 2-Q9
How many times will this loop execute?
int value = 0;
do
{
Console.WriteLine (value);
} while value > 10;
a. 10 times
b. 1 time
c. 0 times
d. 9 times
for ex. to compile, you have to put the condition of while in parantheses otherwise, won t compile, so i d say the correct answer is 0 and not b.1 times
Thank you!
|