24 January, 2008

linq and lambda expressions

i'm aware that i'm about a year (or more, probably) behind on this, but the new c# lambda and linq features are awesome!

i wrote my first dlinq query today, and i'm now of the opinion that linq will literally change the way we code. i'm aware that i don't recognize all of the repercussions that come from linq, but just the very basic queries i did today, literally changed some more of the fundamental programming paradigms i held.

as for lambda expressions, i must say that even though the concept is not new (in fact, anonymous delegates and types are almost as old as programming), there's something to be said for how elegant lambda expression are: what would be ugly (or sometimes even impossible constructs) in c# are extremely simple and easy to read statements thanks to lambda expressions.

i'll keep posting on linq and lambda expressions as i learn more. but if you haven't had a chance to learn about them, i strongly recommend you to.

1 comments:

Mike Murray said...

Here are some cool links about what LINQ is really doing under the covers with those IQueryables and Lambda Expressions:

*Lambda, Lambda, Lambda
*LINQ: Understanding LINQ Vars and Lambdas
*Creating IN Queries with LINQ-to-SQL
*LINQ Gymnastics: Creating a Predictive Query with LINQ

Post a Comment