From: Shai Rosenfeld Date: 2007-07-08T18:28:25+09:00 Subject: simple array question is there a nice clean method to do the following: a = Module.new(:att1 => 1, :att2 => "abc") b = Module.new(:att1 => 1, :att2 => "adfbc") c = Module.new(:att1 => 2, :att2 => "abcasdf") d = Module.new(:att1 => 1, :att2 => "ddddf") e = Module.new(:att1 => 2, :att2 => "ddddf") f = Module.new(:att1 => 3, :att2 => "ddddf") array = [a,b,c,d,e,f] # i want to take the 'array' var and make it into seperate arrays according to the att1 attribute, i.e, resulting in the example above to r1=[a,b,d] r2=[c,e] r3=[f] any nice way to do this? thx -- Posted via http://www.ruby-forum.com/.