Solution to challenge 2
Solution for challenge 3