Archive for March, 2008

Refactoring C# Series: Aggregation of IEnumerable

I was recently reading Programming Ruby: The Pragmatic Programmers’ Guide, Second Edition, and came across this piece of example Ruby code: [1,3,5,7].inject(0) {|sum, element| sum+element} -> 16 [1,3,5,7].inject(1) {|product, element| product*element} -> 105 Inject is a method which acts on an array by aggregating or accumulating the values within that array. It loops through the [...]

More »

A Pure ASP.Net Grid with Grouping

One of my favorite bloggers is Matt Berseth. Nearly once a week he comes up with a post where he does something amazing with the standard ASP.Net controls. I usually read his posts in awe. He’s really good. But he’s not only is a good developer, he’s a great writer. Even though his posts are [...]

More »