Advertisement
Guest User

Untitled

a guest
Feb 26th, 2020
608
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.60 KB | None | 0 0
  1. capacity = int(input())
  2. total_people = 0
  3. space_left = 0
  4. final_price = 0
  5.  
  6. command = input()
  7. while command!="Movie time!":
  8. people = int(command)
  9. price = people*5
  10. if people %3==0:
  11. price -=price*0.05
  12. final_price+=price
  13. total_people += people
  14. if total_people>capacity:
  15. print("The cinema is full")
  16. print(f"Cinema income - {final_price} lv.")
  17. break
  18. command = input()
  19.  
  20. if command == "Movie time!":
  21. space_left=capacity-total_people
  22. print(f"There are {space_left} seats left in the cinema.")
  23. print(f'Cinema income - {final_price} lv.')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement