Loop Control Structure – NFE

Which keyword is used to exit a loop immediately?

 
 
 
 

Which of the following statements is used to skip an iteration of a loop?

 
 
 
 

What will be the output of the following loop?

int i = 1;
while(i <= 3)
{
printf(“%d “, i);
i++;
}

 
 
 
 

Which of the following loops does not necessarily require a loop variable?

 
 
 
 

What is the output of the following code?

int i = 1;
do
{
printf(“%d “, i);
i++;
} while(i <= 3);

 
 
 
 

What will be the output of the following code?

int i = 5;
while(i > 0)
{
printf(“%d “, i);
i–;
}

 
 
 
 

Which loop checks the condition after executing the loop body?

 
 
 
 

Which of the following loops is best when the number of iterations is known?

 
 
 
 

How many times will the following loop execute?

for(int i = 0; i < 5; i++)
{
printf(“Hello\n”);
}

 
 
 
 

Which of the following loops executes at least once?

 
 
 
 

Question 1 of 10