2nd problem set of 6.005