Exercise from the Caelum Ruby on Rails online book