answer to week6-assignment5.