In my last post, I demonstrated an extension method for easy creation of ranges, using the 1.To(x) syntax, similar to the Ruby [1..x] syntax. Today I’m writing another copy of a Ruby idea which lets you do a quick loop using a terse and easy-to-read syntax.
Remember, if you want to create your own extension [...]
Lesen Sie den vollständigen Eintrag unter http://richardbushnell.net/index.php/2008/01/02/fun-with-c-sharp-extension-methods-quick-loops/