Google interview question

DSA, dynamic programming, Backtracking, Trees