Advertisement
PowerCell46

Godzilla vs Kong Python

Dec 15th, 2022
659
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.71 KB | None | 0 0
  1. budget_of_the_movie = float(input())
  2. number_of_extras = int(input())
  3. price_for_one_extra = float(input())
  4. decor_for_the_movie = budget_of_the_movie / 10
  5.  
  6. if number_of_extras > 150:
  7.     price_for_one_extra -= (price_for_one_extra / 10)
  8.  
  9. sum_of_extras_expenses = number_of_extras * price_for_one_extra
  10.  
  11. sum_of_expenses = decor_for_the_movie + sum_of_extras_expenses
  12.  
  13. if budget_of_the_movie >= sum_of_expenses:
  14.     print("Action!")
  15.     left_money = budget_of_the_movie - sum_of_expenses
  16.     print(f'Wingard starts filming with {left_money:.2f} leva left.')
  17. else:
  18.     print(f'Not enough money!')
  19.     needed_money = sum_of_expenses - budget_of_the_movie
  20.     print(f'Wingard needs {needed_money:.2f} leva more.')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement