Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- trip = float(input())
- quantity_puzzles = int(input())
- quantity_puppet = int(input())
- quantity_bear = int(input())
- quantity_minion = int(input())
- quantity_truck = int(input())
- price_puzzle = 2.60
- price_puppet = 3.00
- price_bear = 4.10
- price_minion = 8.20
- price_truck = 2.00
- total_price = quantity_puzzles * price_puzzle \
- + quantity_puppet * price_puppet\
- + quantity_bear * price_bear\
- + quantity_minion * price_minion\
- + quantity_truck * price_truck
- total_toys = quantity_puzzles + quantity_puppet + quantity_bear + quantity_minion + quantity_truck
- if total_toys >= 50:
- total_price = total_price * 0.75 # totalprice*=0.75
- total_price *= 0.9
- remain = abs(total_price - trip)
- if remain >= trip:
- print (f"Yes!{remain:.2f} lv left.")
- else:
- print (f'Not enough money!{remain:.2f} lv needed.')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement