rails tutorial by M. Hartl, chap 2