Bird
0
0

Which of the following best describes the difference between continue and break in a loop?

easy📝 Conceptual Q2 of 15
Python - Loop Control
Which of the following best describes the difference between continue and break in a loop?
A<code>continue</code> skips to the next iteration; <code>break</code> exits the loop entirely.
B<code>continue</code> exits the loop; <code>break</code> skips to the next iteration.
C<code>continue</code> restarts the loop; <code>break</code> pauses the loop.
D<code>continue</code> pauses the loop; <code>break</code> restarts the loop.
Step-by-Step Solution
Solution:
  1. Step 1: Define continue behavior

    continue skips the rest of the current iteration and moves to the next iteration.
  2. Step 2: Define break behavior

    break immediately exits the entire loop, stopping all further iterations.
  3. Final Answer:

    continue skips to the next iteration; break exits the loop entirely. -> Option A
  4. Quick Check:

    Continue vs Break = skip iteration vs exit loop [OK]
Quick Trick: Continue skips iteration; break stops loop completely [OK]
Common Mistakes:
MISTAKES
  • Mixing up continue and break effects
  • Thinking break skips iteration
  • Assuming continue exits loop

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Python Quizzes