Home › Course contents › Level 5: The secret of quotes
Text vs numbers
Level 5: The secret of quotes
Chapter 1 · Starter Village
See how these two lines differ:
print("7 + 8") # with quotes: treated as text, said as-is
print(7 + 8) # no quotes: treated as math, gives 15
Remember: quotes = text, no quotes = numbers or math.
GoalMake {PET} first say the problem 7 + 8, then the answer 15.
TipTwo lines in total: one with quotes, one without.
Starting code
# Line 1: with quotes, say the problem 7 + 8
# Line 2: no quotes, work out the answer