LLD - Design — Splitwise (Expense Sharing)
Consider this pseudocode for balance calculation:
What will be the printed balance?
balance = 100
transactions = [20, -10, 30, -5]
for t in transactions:
balance += t
print(balance)What will be the printed balance?
