Apple Interview Question

Two leetcode dynamic programming questions