Hi. I want to have an array of instances.......

listb = [instance1, instance2, instance3]

I am able to print out the instance.....

def printout(an_array)
an_array.each {|item| p item }
end
printout(listb)


How can I print out specific variables for each instance?


eg variables...

name
age
-- 
Posted via http://www.ruby-forum.com/.