Exploring array comprehensions
Cleaned up and documented code