Solution to Exercise 2

Solution to exercise 2.

We'll cover the following

Solution #1