Lesson 33 of 79 · 15 minutes
Counting and adding up: Piggy Bank
Coins drop in one at a time, and the total climbs as your code runs.
This game is part of the full course.You own the full course.
Unlock all 79 Python coding games for $9, once.Opening the game…
Unlock for $9Play now
What you'll learn
- Adding things up
- Adding the loop variable
- Counting only some things
- A total and a count together
- Starting the total in the wrong place
Each idea opens with a short narrated video, about 2 minutes in all. Then you put it to work in the game.
The six levels
- Bigger Coins Change it
- 1 to 10 Copy and type
- Only the Evens Fill the gap
- Fives Only Write it
- Vanishing Coins Fix it
- A Random Pile Boss level
The levels go from changing one word, to writing the code on your own. The boss level changes every time you play.
New to Python? Start with the free games in Module 1.