← Quiz: Python Loops: all 13 questions
Quiz: Python Loops · Question 2 of 13
How many times does the body run? for i in range(2, 20, 3):
How many times does the body run? for i in range(2, 20, 3):
- A.5
- B.6
- C.7
- D.18
Answer & explanation
Correct answer: 6
The values are 2, 5, 8, 11, 14, 17 — six values (20 is not reached).
Can you get the rest right without peeking?
Take the timed Quiz: Python Loops quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →