Too Long; Didn't Read
How to Solve 6 Dynamic Programming Problems In a Systematic Way. I will solve 6 harder Dynamic Programming problems to show you how to approach them. These two new problems are just instances of the original problem. If you suspect a problem might be solved via Dynamic Programming, I recommend drawing a tree with all possible paths to see if there are repeated subproblems. The bottom-down approach is trivial. There are two nested loops in which the time of work is constant, giving an overall complexity of work.