Home › Course contents › Level 4: A partner who can count
Numbers and math
Level 4: A partner who can count
Chapter 1 · Starter Village
You can also put a math problem inside the brackets. Numbers don't need quotes, and your partner works out the answer:
print(3 + 5) # your partner says 8
print(10 - 4) # your partner says 6
Text after # is called a comment. It's a note for humans, and the computer skips it.
GoalMake {PET} work out what 12 + 30 equals.
TipUse * to multiply and / to divide, for example print(6 * 7).
Starting code
# Make {PET} work out 12 + 30 (no quotes around the numbers)