From: Marnen Laibow-Koser Date: 2009-12-21T04:04:43+09:00 Subject: Re: how to put unique lines from regexped file Robert Klemme wrote: > On 20.12.2009 15:40, W. James wrote: >> >> That's fine for the plodding proles, but we cossacks always shout the >> battle-cry: "We don't need no stinkin' loops!" >> >> puts IO.readlines('aa.xml').map{|s| s.sub( ... )}.uniq >> >> Everything must be done in one fell swoop or not at all! > > Strong words, but I hope you are aware that this, taken as a general > rule, is bad advice. @geekdom = {@everything.reject {|e| !e.fell_swoop?}}.good_advice? ? :alive : :dead :) > > Cheers > > robert Best, --  Marnen Laibow-Koser http://www.marnen.org marnen@marnen.org  -- Posted via http://www.ruby-forum.com/.