[Boulder Ruby Group] Anyone else see this?
Tony Arcieri
tony at clickcaster.com
Sat Jun 30 01:54:10 EDT 2007
http://m.onkey.org/2007/6/30/let-s-start-with-wtf
Just did my own little test...
~$ irb -rbenchmark -rubygems -ractive_support
>> class Fixnum; def timestwo; self * 2; end; end
=> nil
>> puts Benchmark.measure { (1..10000000).map { |n| n.timestwo } }
13.570000 0.100000 13.670000 ( 13.795564)
=> nil
>> puts Benchmark.measure { (1..10000000).map(&:timestwo) }
48.370000 0.080000 48.450000 ( 48.517666)
=> nil
Yikes
--
Tony Arcieri
ClickCaster, Inc.
tony at clickcaster.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/bdrg-members/attachments/20070629/0bd36c24/attachment.html
More information about the Bdrg-members
mailing list