← Back to archive

Stdle #84 · iteration · 2026-08-29

What does this Python snippet output?

A past puzzle — fully playable. 4 attempts, hints on wrong guesses.

nums = [1, 2, 3]
for n in nums:
if n == 2:
break
else:
print("done")
print("after")
Iteration
4 attempts left

Answer & explanation