From Dev.to
Debt snowball vs avalanche in 40 lines of JavaScript
Both payoff methods are a tiny simulation: accrue interest, pay every minimum, then send whatever is left to one target debt. The only difference is how you pick the target. Snowball: smallest balance...
