Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- transactions = int(input())
- bank_sum = 0
- counter_transaction = 0
- while counter_transaction < transactions:
- current_sum = float(input())
- if current_sum < 0:
- print('Invalid operation!')
- break
- print(f'Increase: {current_sum:.2f}')
- bank_sum += current_sum
- counter_transaction += 1
- print(f'Total: {bank_sum:.2f}')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement