-
April 29th, 2014, 12:49 PM
#1
coin change problem
Illustrate the execution of the Coin Change algorithm on n = 10 in the system of denominations d(1) = 1, d(2) = 5, and d(3) = 8.
so i have n = 10 with denominations of d(1) = 1, d(2) = 5, d(3) = 8
so the execution of the coin problem will be: 1 * 1 + 2 * 5 + 3 * 8
so it will be using 2 nickels of 5. is this right or am i doing something wrong.
-
April 29th, 2014, 02:43 PM
#2
Re: coin change problem
Yes, "2 nickels of 5" is less than for example "1 of 8 plus 2 of 1".
However, I don't see any algorithm in your OP.
Victor Nijegorodov
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|