Math & Trig
Cash denomination calculator: break amounts into $100, $50, $20, $10, $5, $1 bills
Compute the minimum number of banknotes for cash envelopes and register drawers using INT and sequential MOD remainders.
Watch out for the $50-to-$20 remainder trap
For $387, INT(387 / 100) gives three $100 bills ($87 left) and INT(MOD(387, 100) / 50) gives one $50 bill ($37 left).
Never compute $20 bills as INT(MOD(387, 20) / ...), because 50 is not a multiple of 20! Always pass the remainder AFTER removing $100s and $50s—MOD(MOD(Amount, 100), 50)—into the $20 step (INT(37 / 20) = 1 bill, leaving $17 = one $10, one $5, and two $1s).
| CashPayout (A) | $100 Bills | $50 Bills | $20 Bills | $10 / $5 / $1 |
|---|---|---|---|---|
| 387 | 3 | 1 | 1 | 1 / 1 / 2 (Total = $387) |
| 245 | 2 | 0 | 2 | 0 / 1 / 0 (Total = $245) |
Sequential denomination formulas
Verify that the weighted sum of all bill counts equals the original payout ($300 + $50 + $20 + $10 + $5 + $2 = $387).
=INT(A2 / 100)$20-bill count after $100 and $50 bills
MOD(MOD(A2, 100), 50) isolates the post-$50 remainder ($37), yielding 1 twenty-dollar bill.
=INT(MOD(MOD(A2, 100), 50) / 20)Complete the $10 and $5 bill counts
Use the remainder after all larger denominations. The remaining $1 count is the final remainder modulo 5. This example assumes a nonnegative whole-dollar amount and an unlimited supply of the listed bills; it does not handle cents or drawer inventory constraints.
=INT(MOD(MOD(MOD(A2,100),50),20)/10)Five-dollar bills
For $387 this gives one $5 bill; together with the other denominations the total is $387.
=INT(MOD(MOD(MOD(MOD(A2,100),50),20),10)/5)Try the example
Use the original values or change them to test your understanding.