python (65.2k questions)
javascript (44.3k questions)
reactjs (22.7k questions)
java (20.8k questions)
c# (17.4k questions)
html (16.3k questions)
r (13.7k questions)
android (13k questions)
Identifying when greedy method gives optimum solution
I was looking at this problem on leetcode
https://leetcode.com/problems/minimum-number-of-operations-to-convert-time/description/
The hints tell us to follow a greedy approach where we convert the tim...

Clarence Callahan
Votes: 0
Answers: 1
How can I add limited coins to the coin change problem? (Bottom-up - Dynamic programming)
I am new to dynamic programming (and C++ but I have more experience, some things are still unknown to me). How can I add LIMITED COINS to the coin change problem (see my code below - is a bit messy bu...
Alin M.
Votes: 0
Answers: 2
Simple algorithm to compute coins that form minimum number of coins (or any valid number of coins) from a limited number of coins
I need to find the coins needed to make up a specified amount, not the number of ways or the minimum number of coins, but if the coins end up a minimal number then that's ideal.
For example, we have c...
Silo2017
Votes: 0
Answers: 1
Coin change recursive implementation memoizing wrong values. Could someone help debug?
Could someone help me figure out why this version of the memoized coin change doesn't work?
This is to determine the minimum number of coins to make change for a target amount.
I realize that the cach...
user16518823
Votes: 0
Answers: 2