SectionΒ 4. ChapterΒ 11
ninja.py
Triangle Collection Revisited
Swipe to show menu
You have already seen how nested loops help solve problems with repeating patterns.
So far, you have used nested for loops when the number of repetitions was known in advance.
But in some Ninja game tasks, the number of repetitions depends on what is happening in the game, not on a fixed number. That is where nested while loops are useful.
Task
Swipe to start coding
Solution
Explore other courses in Catalog
Everything was clear?
Thanks for your feedback!
SectionΒ 4. ChapterΒ 11
ninja.py
Ask AI
Ask AI
Ask anything or try one of the suggested questions to begin our chat