Added solutions to problem 2 and 4