From: Jeff Putsch Date: 2003-02-13T05:50:40+09:00 Subject: Re: hm,... arr[1]["name"] How about: arr = [] (0..9).each { |i| arr[i] = {} arr[i]["name"] = daniel arr[i]["age"] = 20 } Jeff. On Thu, Feb 13, 2003 at 05:45:18AM +0900, daniel wrote: > $arr = Array(); > for( $i=0; $i<10; $i++ ) > { > $arr[$i]["name"] = "daniel"; > $arr[$i]["age"] = 20; > } > > This was php. > How to do this in ruby? > > Until yet the best way I found was to create two classes... > I come from c/c++ and php - so I don't know how perl > manage such things. In the ruby documentations arrays would > not expatiated. > > > daniel > > > -- Jeff Putsch Email: putsch@mxim.com Maxim Integrated Products Office: (503)547-2037 High Frequency CAD Engineering