Okay so I'm making progress...
I set the purchase at .25 and Pay with 1 penny, 1 dime, 8 quarters, and 1 nickel ($2.16)
So I should get back 1.91
Here is the Output
The Change Due is:...
Type: Posts; User: bengregg
Okay so I'm making progress...
I set the purchase at .25 and Pay with 1 penny, 1 dime, 8 quarters, and 1 nickel ($2.16)
So I should get back 1.91
Here is the Output
The Change Due is:...
So I put the code in the givechange() method instead and it gave me the result of 25.
I found out this result is the total amount of coins to give back.
return dollarsint + quartersint + dimesint +...
Okay So I went back and had the doubles converted to ints. Lol, however, I had to convert them back to double so the equations would work. I'm error free however, when I call the method it gives me...
I am working on a program where you have to give change in coins. The program already gives the change amount, I'm just trying to figure out how to give the change in coins. This is what i have so...