0 / 2 embers
0 / 3000 xp
click for more info
Complete a lesson to start your streak
click for more info
Difficulty: 3
click for more info
No active XP Potion
Accept a Quest
Login to submit answers
Now that we know how to store and change the value of variables let's do some math!
Here are some examples of common mathematical operators in Python syntax.
summation = a + b # Addition
difference = a - b # Subtraction
product = a * b # Multiplication
quotient = a / b # Division
Parentheses can be used to order math operations.
avg = (a + b + c) / 3
Create a new variable called armored_health
on line 4 and set it equal to player_health * armor_multiplier
Focus Editor
Alt+Shift+]
Login to Submit
Login to Run
Login to view solution