Meta interview question

Tree search question + max subsequence