The basics · Decisions
Combining conditions
and, or, not — and why the order of your checks still matters. · 8 minutes
Predict first
What does this print?
1age = 152if age < 13 or age > 19:3print("not a teenager")4else:5print("teenager")
The basics · Decisions
and, or, not — and why the order of your checks still matters. · 8 minutes
Predict first
What does this print?
1age = 152if age < 13 or age > 19:3print("not a teenager")4else:5print("teenager")