Conditional Statements: if, elif, else in Python


Control the flow of your program with conditional statements.

Source Code

age = 20
if age >= 18:
    print("Adult")
elif age >= 13:
    print("Teenager")
else:
    print("Child")
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments