If you want a loop to run until it finds a specified value, what type of loop would you use?
-
A For Each…Next loop.
-
A Do...Loop.
-
A Loop-dee-Loop.
-
None of the above
B
Correct answer
Explanation
When you need to loop until finding a specified value, a Do...Loop is the appropriate choice. It allows you to continue iterating until a condition (like finding a target value) is met, using either Do Until value_found or Do While Not value_found. For Each...Next loops are designed for iterating through collections/arrays where you visit every element, not for stopping at a specific match. Option C is a nonsensical distractor.