Skip to content

Commit

Permalink
fix: issue with cash register input check (#595)
Browse files Browse the repository at this point in the history
  • Loading branch information
Auxdible authored Apr 17, 2024
1 parent 8a76179 commit 6adab1c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/cash-register/public/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ const checkCashRegister = () => {
}

for (let i = 0; i <= reversedCid.length; i++) {
if (changeDue > denominations[i] && changeDue > 0) {
if (changeDue >= denominations[i] && changeDue > 0) {
let count = 0;
let total = reversedCid[i][1];
while (total > 0 && changeDue >= denominations[i]) {
Expand Down

0 comments on commit 6adab1c

Please sign in to comment.