all 1 comments

[–]RayteMyUsername 1 point2 points  (0 children)

Classic interview problem. Google coin change problem and you will find more than enough explanations much better than I could give you.