Question related to Exact Change

Question related to Exact Change
0.0 0

#1

One of the test cases:
checkCashRegister(19.50, 20.00, [[“PENNY”, 0.01], [“NICKEL”, 0],
[“DIME”, 0], [“QUARTER”, 0], [“ONE”, 1.00], [“FIVE”, 0], [“TEN”, 0],
[“TWENTY”, 0], [“ONE HUNDRED”, 0]]) should return “Insufficient Funds”.

Could some one tell me why this should return “Insufficient Funds” even there is enough money in the cashier?

-Zumi-


#2

You can’t give 50 cents change with one dollar and one penny.


#3

Of course :grin: thank you