DatadogSoftware Engineer · Technical ScreenCodemia practiceFind longest subsequence in binary tree
Given a binary tree, write a function to find the longest subsequence of nodes where each node's value is greater than its parent node's value. The function should return the length of this longest subsequence. The input will be the root node of the binary tree, and the output should be an integer representing the length of the longest increasing subsequence.
Medium
Coding & Algorithms