CT098

Coin Sums

MediumAcceptance: 0.0%

In England the currency is made up of pound and pence. There are eight coins in general circulation: 1p, 2p, 5p, 10p, 20p, 50p, 100p, and 200p. Given target T (in pence), find the number of different ways T can be made using any number of coins.

Example 1:

Input: 5
Output: 4

Example 2:

Input: 200
Output: 73682

Example 3:

Input: 10
Output: 11

Constraints:

1 <= T <= 10^4

Tags:

dynamic-programming coins combinatorics
Loading...
Test Cases:No test cases
No test cases available.