Advertisement
JkSoftware

Day 3 - is else and conditional statements

Nov 5th, 2021
812
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. print("Welcome to the rollercoaster!")
  2. height = int(input("What is your height in cm? "))
  3. diff = 120 - height
  4. if height >= 120:
  5.     print("Heres a ticket")
  6. else:
  7.     print(
  8.         f"Sorry you need to grow {diff}cm taller to ride :("
  9.     )
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement