Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Conditional Operators
- # == equals
- # > greater than
- # < less than
- # >= greater than or equal to
- # <= less than or equal to
- # Control Flow Statements
- age = int(input("What is your age? "))
- if age < 19:
- print("You cannot enter the bar")
- else:
- print("You can enter the bar!")
- name = input("What is your name?")
- if name == "Jeremy":
- print("Welcome to the bar Jeremy! (Happy Birthday!)")
- elif name == "Antoine":
- print("Long time no see! Welcome back Antoine!")
- else:
- print("Welcome to the bar! I don't think you've been here before!")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement