I'm trying to create a spreadsheet to track deposits into an account with a set yearly maximum. However, "unused" previous years can be added to the total available room.
This leaves me with unequal values though, and I can't end up with a negative amount. If I have a column with available room per year, and another column for payments per year, then I could manually add up the amount used and subtract a portion of the running total from each row. But I feel like there should be a way to come up with a smarter formula to do that.
Something like this would be the end result:
I've found articles/solutions suggesting ArrayFormula for kinda similar calculations (like debt payments), but they don't quite get me this far. Is there a solution?
