Problem 1 finished. Working on problem 2 asap.