Tested and corrected answer to question 1