Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- price_trip = float(input())
- count_puzzle = int(input())
- count_dolls = int(input())
- count_bears = int(input())
- count_minions = int(input())
- count_trucks = int(input())
- price_toys = count_puzzle * 2.60 + count_dolls * 3 + count_bears * 4.10 + count_minions * 8.20 + count_trucks * 2
- count_toys = count_trucks + count_bears + count_puzzle + count_minions + count_dolls
- if count_toys >= 50:
- price_toys -= 0.25 * price_toys
- rent = 0.10 * price_toys
- all_money = price_toys - rent
- if all_money >= price_trip:
- print(f"Yes! {abs(price_trip - all_money):.2f} lv left.")
- else:
- print(f"Not enough money! {abs(all_money - price_trip):.2f} lv needed.")
Advertisement
Add Comment
Please, Sign In to add comment