From: Matt Armstrong Date: 2003-02-19T15:05:08+09:00 Subject: Re: String#+ operatorbroken? Jim Freeze writes: > On Wednesday, 19 February 2003 at 9:47:53 +0900, Jim Freeze wrote: >> >> 100000.times { |i| >> s << "fred\n" # this completes in less than 1 second >> #s += "fred\n" # this blows up real fast > > To be more clear, 'blows up' refers to time and not necessarily memory. The "+=" version runs really slow in both ruby 1.6.8 and current CVS (1.8.0). The "<<" version runs much faster in both. -- matt