implement episode 5 & 6 railscast