solution to 3.5