Hi,
I am trying to make a multi-dimensional array of characters in ruby, and this works, but is there a more elegant way?
def initialize(text)
@map = Array.new
i = 0
text.split("\n").each do |x|
@map[i] = x.scan(/./)
i += 1
end
#@map = text
end#constructor