In article <95ia88$vuk$1 / nnrp1.deja.com>, Jason <jasowong / my-deja.com> wrote: >Hi All, > >a. Is a multi-dimensional array the best way to track this information? >b. Does Ruby have support for it? >c. Is there a better way to keep the information? I won't touch questions 'a' and 'c' because others have. But Ruby makes multi-dimensional arrays really easy to construct: class Matrix < Array def initialize (rows, columns) super(rows) self.each_index { |i| self[i] = Array.new(columns) self[i].each_index { |j| self[i][j] = rand(10) } } end end arr = Matrix.new(12, 15) arr.each { |i| p i } arr.each { |i| i.each { |j| p j } } arr.each_index { |i| arr[i].each_index { |j| puts "#{i},#{j} -> #{arr[i][j]}" } } Ruby is so much fun! =) Jeremy