๐ Beginning Python Programming
/
Controlling logic flow
/
if...:
If condition example
score = 61
if score >= 60:
print("Pass")
else:
print("Fail")
Key points to use if condition.
- Make sure there is a colon at the end.
- Anything that depends on the condition is indented with 4 spaces.
# Giving the following variable
age = 28