Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- budget = float(input())
- capital = float(input())
- number_investors = int(input())
- counter = 1
- while counter <= number_investors:
- investor_sum = float(input())
- print(f"Investor {counter} gave us {investor_sum:.2f}.")
- capital = capital + investor_sum
- if capital >= budget:
- extra_money = capital - budget
- print(f"We will manage to build it. Start now! Extra money - {extra_money:.2f}.")
- exit(0)
- else:
- counter += 1
- extra_money = budget - capital
- print(f"Project can not start. We need {extra_money:.2f} more.")
Advertisement
Add Comment
Please, Sign In to add comment