Code practice from the book "AngularJS in Action"