Explanatory Question
Analyse the following program segment and determine how many times the loop will be executed and what will be the output of the program segment:
int p = 200;
while(true)
{
if(p < 100)
break;
p = p - 20;
}
System.out.println(p);
Read the answer carefully and go through the related questions on the right side to improve your understanding of this topic.