On Wednesday, February 8, 2012 3:41:45 AM UTC+1, Eilie wrote:
> On 2012-02-07, sreservoir <
srese...@gmail.com> wrote:
> > On 02/07/2012 05:59 PM, Eilie wrote:
> >> I tryed already:
> >>
> >> 5.times {|n| eval "house#{n} = Array.new(5)"}
> Yeah, you're right. Hash better choice for that, sorry for disturbance.
Why not an Array? You are indexing by integer anyway.
Assuming you really want five Arrays of length five each:
houses = Array.new(5) { Array.new(5) }
Cheers
robert