Ruby on rails study code