Dp state identification

can anyone please tell me their thought process in identifying a dynamic programming state?
how do u solve a dp problem step by step?

There are so many tutorials, but it pointless going through them, it needs TIME and PRACTICE


I guess you should practice many problems…

1 Like

The most Important thing to find is Overlapping Sub problems, Its Identification alone suggests its a DP problem. But to identify that requires a lot of practice and patience. Try to solve some standard DP problems first like Knapsack, Coin -change, LIS, LCS etc. Then Try their modifications. Solve as many as you can.

1 Like