Question: Consider the code below. Which of the lines of code can replace the code block to result in 2 being printed for count? int
Consider the code below. Which of the lines of code can replace the code block to result in 2 being printed for count?
int count = 20;
** code block **
{
count /= 2;
}
System.out.println(count);
A while (count == 5)
B while (count < 5)
C while (count > 5)
D while (count <= 5)
E while (count >= 5)
Step by Step Solution
There are 3 Steps involved in it
10 The correct Option is OOptionE Explanation We should loop till the value is greate... View full answer
Get step-by-step solutions from verified subject matter experts
