How to think of DP for this problem?

  • 0

    Can someone share how they arrived at the DP solution? I only was able to come up with naive recursive solution... like how did it occur to you to use dynamic programming?

Log in to reply

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.