2.times { deck.shuffle }
is much more expressive than
for(i=0; i<2; ++i) deck.shuffle [/sourcecode]
Tweet This Post Digg This Post Reddit Stumble This Post
This entry was posted on Wednesday, August 19th, 2009 at 11:16 am and is filed under Ruby. You can follow any responses to this entry through the RSS 2.0 feed. Both comments and pings are currently closed.
Comments are closed.
Subscribe to this site's RSS feed.