Advertisement
bl00dt3ars

03. Excursion Calculator

Dec 14th, 2020
374
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.53 KB | None | 0 0
  1. people = int(input())
  2. season = input()
  3.  
  4. if season == "spring":
  5.     if people <= 5:
  6.         price = people * 50
  7.     else:
  8.         price = people * 48
  9. elif season == "summer":
  10.     if people <= 5:
  11.         price = people * 48.5 * 0.85
  12.     else:
  13.         price = people * 45 * 0.85
  14. elif season == "autumn":
  15.     if people <= 5:
  16.         price = people * 60
  17.     else:
  18.         price = people * 49.5
  19. else:
  20.     if people <= 5:
  21.         price = people * 86 * 1.08
  22.     else:
  23.         price = people * 85 * 1.08
  24.  
  25. print(f"{price:.2f} leva.")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement