Amazon interview question

RECURSION questions backtracking approach (subseq)