puts "\nMODULE : "
Module.constants.sort.select { |x| eval(x.to_s).instance_of? Module }
puts"\nCLASSES : "

puts Module.constants.sort.select { |x|
   c = eval(x.to_s)
  c.is_a? Class and not c.ancestors.include? Exception
}
puts " \nEXCEPTIONS :"
puts Module.constants.sort.select {|x|
  c = eval(x.to_s)
  c.instance_of? Class and  c.ancestors.include? Exception
}



Above code is taken from 'The Ruby Programming Language'; it prints all
the modules , clases and exception classes when the interpreter is
loaded ; however i want the output in row column form...please help
-- 
Posted via http://www.ruby-forum.com/.