Coins of 1, 3 and 4 — Solution & Editorial
Unbounded-knapsack DP over amounts. (This set has a known O(1) pattern, but the DP is a clean reference.)
Complexity: O(N)
Unbounded-knapsack DP over amounts. (This set has a known O(1) pattern, but the DP is a clean reference.)
Complexity: O(N)