I have a question regarding one test case


  • 0
    M

    What if the coins is {5,2,2,2,2} and target amount is 10?
    The OJ gives the result of 2 but how does this 2 comes from?


  • 0
    M

    Using 2 '5's.
    You have infinite amount of coin of each denomination.


Log in to reply
 

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.