Solution to Problem 3.2 from longer problems in Module 4.pdf