From: Day Date: 2008-02-16T01:47:24+09:00 Subject: Re: Which data-type can I use for this task? On Fri, Feb 15, 2008 at 10:34 AM, Adna rim wrote: > Now I wanna store them in a data type like an array. I tied this here: > > information = [Street=[],House=[],Person=[],Age=[]] > > but If I wanna now fill it like > > information.Street << firstentry > > I always get an error telling undefined method Street... With which > datatype do I best realize this? I vote for an array of hashes. Each entry is a hash, composed thusly: info = {:street => '1234 Street st.', :house => 'purple', :person => 'some guy', :age => 'a billion.'} So you can set a given piece with: info[:street] = '4321 Avenue Blvd.' Sound like what you want? Ben