Suppose there are 5 types of coins: 50-cent, 25-cent, 10-cent, 5-cent, and 1-cent. We want to make changes with these coins for a given amount of money.
InputThe input file contains any number of lines, each one consisting of a number for the amount of money in cents.OutputFor each input line, output a line containing the number of different ways of making changes with the above 5 types of coins.Sample Input
11 26 Sample Output4 13
This problem is used for contest: 81 Submit / Problem List / Status / Discuss #include<stdio.h> |
DP-1424: Coin Change
最新推荐文章于 2019-04-15 20:00:34 发布