I struggled to understand what “Annual Balance Update” meant until I searched and found an answer in another thread.
I take the word update to mean “difference” in this case, not the total after interest is added. I understand that others read it differently.
The name of the method might be better named something like UpdatedAnnualBalance or AdjustedAnnualBalance.
An easier way to resolve this would be to change the definition of “annual balance update” so it’s clearer what is expected.
For example:
3. Calculate the annual balance update
Implement the (static) SavingsAccount.AnnualBalanceUpdate() method to calculate the annual balance update, taking into account the interest rate.
The annual balance update is the balance of the account after the interest has been added to the balance at the end of the year.
SavingsAccount.AnnualBalanceUpdate(balance: 200.75m)
// 201.75375m
If either of the above suggestions are of interest (sorry) I would be happy to submit a PR for review.
Thoughts?