Apple interview question

Several questions requiring recursion/dynamic programming to solve.