In programming, a loop that executes at least once regardless of condition is called a ________ loop.
- Green
- Inversion
- Artifact / Model Registry
- do-while
Answer: do-while
do-while loop checks the condition AFTER executing the loop body, guaranteeing at least one execution. In contrast, while and for loops check condition BEFORE execution, potentially skipping the body entirely if condition is initially false. Syntax varies by language but logic remains consistent.