Advertisement
dkyoseff

Conditional Statements Advanced - Exercise / 02. Summer Outfit

Jul 26th, 2022
952
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 1.04 KB | None | 0 0
  1. degrees = int(input())
  2. part_of_the_day = str(input())
  3.  
  4. if 10 <= degrees <= 18:
  5.     if part_of_the_day == "Morning":
  6.         outfit = "Sweatshirt"
  7.         shoes =  "Sneakers"
  8.     elif part_of_the_day == "Afternoon":
  9.         outfit = "Shirt"
  10.         shoes = "Moccasins"
  11.     elif part_of_the_day == "Evening":
  12.         outfit = "Shirt"
  13.         shoes = "Moccasins"
  14.  
  15. elif 18 < degrees <= 24:
  16.     if part_of_the_day == "Morning":
  17.         outfit = "Shirt"
  18.         shoes = "Moccasins"
  19.     elif part_of_the_day == "Afternoon":
  20.         outfit = "T-Shirt"
  21.         shoes = "Sandals"
  22.     elif part_of_the_day == "Evening":
  23.         outfit = "Shirt"
  24.         shoes = "Moccasins"
  25.  
  26. elif degrees >= 25:
  27.     if part_of_the_day == "Morning":
  28.         outfit = "T-Shirt"
  29.         shoes = "Sandals"
  30.     if part_of_the_day == "Afternoon":
  31.         outfit = "Swim Suit"
  32.         shoes = "Barefoot"
  33.     if part_of_the_day == "Evening":
  34.         outfit = "Shirt"
  35.         shoes = "Moccasins"
  36.  
  37. print(f"It's {degrees} degrees, get your {outfit} and {shoes}.")
  38.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement