Squarepoint Capital interview question

leetcode problem was about dynamic programming