Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- budget = float(input())
- gpu = int(input())
- cpu = int(input())
- ram = int(input())
- gpu_price = gpu * 250
- cpu_price = cpu * gpu_price * 0.35
- ram_price = ram * gpu_price * 0.10
- total = gpu_price + cpu_price + ram_price
- if gpu > cpu:
- total *= 0.85
- if budget >= total:
- print(f'You have {budget - total:.2f} leva left!')
- else:
- print(f'Not enough money! You need {total - budget:.2f} leva more!')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement