**The Idea of Developing a DP Algorithm :**__Characterize the structure of an optimal solution.__

**Step 1: Structure :**-Decompose the problem into smaller problems, and find a relation between the structure of the optimal solution of the original problem and the solutions of the smaller pronlms.

__Recursively define the value of an optimal solution.__

**Step 2 : Principle of Optimality :**-Express the solution of the original problem in terms of optimal solutions for smaller problems.

__Compute the value of an optimal solution in a bottom-up fashion by using a table structure.__

**Step 3 : Bottom-up computation:**__Construct an optimal solution from computed information.Steps 3 and 4 may often be combined.__

**Step 4 : construction of optimal Solution :**