Squarepoint Capital interview question

Longuest increasing sunsequence leetcode hard