Design Dynamic Programming Algorithm Problem Define Original Problem Function Takes Parame Q37248841

Design a dynamic programming algorithm for the problem.

• Define the original problem as a function that takes parameters,and return some results.

• Define the subproblems

• Write recursive formula that relates a problem’s solution tosolutions of smaller subproblems.

• Finally write out pseudocode for the algorithm (using top-downmemoization or bottom-up)

Suppose a list P[1.. ] gives the daily stock price of a certain company for a duration of n days, we want to find an optimalSuppose a list P[1.. ] gives the daily stock price of a certain company for a duration of n days,

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.