Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- price_of_trip = float(input())
- number_of_puzzles = int(input())
- number_of_dolls = int(input())
- number_of_bears = int(input())
- number_of_minions = int(input())
- number_of_trucks = int(input())
- amount_puzzle = number_of_puzzles * 2.60
- amount_dolls = number_of_dolls * 3
- amount_bears = number_of_bears * 4.10
- amount_minions = number_of_minions * 8.20
- amount_trucks = number_of_trucks * 2
- toys_count = (amount_puzzle + amount_dolls + amount_bears + amount_minions + amount_trucks)
- total_sum = (number_of_puzzles + number_of_dolls + number_of_bears + number_of_minions + number_of_trucks)
- if toys_count >= 50:
- total_sum *= 0.25
- total_sum = toys_count * 0.9
- if total_sum >= price_of_trip:
- print(f"Yes! {total_sum - price_of_trip:.2f} lv left.")
- else:
- (f"Not enough money! {price_of_trip - total_sum:.2f} lv needed.")
Advertisement
Add Comment
Please, Sign In to add comment