Solution for Challenge 2