Important MCQ

while(1) is

Q.while(1) is

A) a loop that runs once
B) an error
C) a loop that never runs
D) an infinite loop
Correct Answer:
Option D
Detailed Explanation:
D) an infinite loop is correct. A while loop checks its condition before each iteration, so it may run zero times. The loop body must update state when needed to avoid an unintended infinite loop.