Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- money_needed = float(input())
- puzzels = int(input())
- dalls = int(input())
- bears = int(input())
- minioni = int(input())
- tracks = int(input())
- puzzelPrice = puzzels * 2.60
- dallsPrice = dalls * 3
- bearsPrice = bears * 4.10
- minionsPrice = minioni * 8.20
- trackPrice = tracks * 2
- total_number_of_toys = puzzels + dalls + bears + minioni + tracks
- tota_sum_money = puzzelPrice + dallsPrice + bearsPrice + minionsPrice + trackPrice
- final_sum = 0
- final_sum_after_rent = 0
- if total_number_of_toys>=50:
- final_sum = tota_sum_money - (tota_sum_money * 0.25)
- final_sum_after_rent = final_sum - (final_sum * 0.10)
- else:
- final_sum_after_rent = tota_sum_money - (tota_sum_money * 0.10)
- if final_sum_after_rent >= money_needed:
- print(f"Yes! {(final_sum_after_rent - money_needed):.2f} lv left.")
- else:
- print(f"Not enough money! {(money_needed - final_sum_after_rent):.2f} lv needed.")
Advertisement
Add Comment
Please, Sign In to add comment