Question 1 of 5
How does the lesson say to choose between
for and
while?
Pick between for and while by looking at what decides the stopping, the quick check says.
for walks what you can see, a collection with a known end, while while repeats until something changes. The lesson's while carried two facts, the bread and the queue, and stopped when either ran out.
Review this lesson