solve the unique paths II problem.