#T624. 货币系统
货币系统
Description
Given a monetary system with n types of denominations, determine how many ways there are to form the amount m using these denominations. Example: Let n=3, m=10. The required input and output formats are as follows:
Input Format
The first line contains two integers, n and m (m ≤ 5000).
The following n lines each contain an integer, where the (i+1)-th line represents the denomination of the i-th type of currency.
Output Format
An integer representing the number of possible combinations.
```input1 3 10 1 2 5 ``` ```output1 10 ``` ## 代码在线