How to return a two dimensional array?

Hi Everyone,
Can anyone tell me how to return a two dimensional array from a
Function?
I tried "returning(value)" function, but it allows only single
dimensional array.

Thanks in advance.

Regards,
VASANTH

returning an array works fine for me:

def two_dimensional(size, val)
  Array.new(size, Array.new(size, val))
end

two_dimensional(4,1)

=> [[1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1]]

Mike