Earlier quoted context omitted.
Linq is freaking sweet. I miss it every weekday I have to write C# 2.0 and every weekend I write Python. Anyone interested in pragmatic programming languages owe it to themselves to learn a bit about Linq and why it is so pleasant to use. The best way to learn Linq is with the 101 samples [1], but I might be bias because my friend wrote them [2]. [1] http://msdn.microsoft.com/en-us/vcsharp/aa336746.aspx [2] http://ww…
I haven't used Python since 2004, and never became an expert. But isn't is possible to achieve most of what LINQ does in Python? I know in Ruby it's possible to call sort with a block ( http://snippets.dzone.com/posts/show/2120 ). IMHO, that code resembles the spirit of LINQ. That's without even touching on the ActiveRecord portion of Rails which achieves a lot of what LINQ does too. There's got to be a way to do thi…
I don't know much Ruby, but I'd suspect that blocks can simulate Linq far better than Python can. However, the Lambda-inspired syntax is a bit cluttered when compared to the SQL-inspired syntax.
Linq is a feature about 3 things:
1) Correctness via static typing checks
2) Interoperability of various data backends (Microsoft provides backends for XML, SQL, and .NET objects)
3) Clean and beautiful code
Neither Python nor Ruby can provide #1 (at compile time, anyway). SqlAlchemy and other projects attempt #2, but I don't have enough experience with them to comment on their success. And while Python as a whole (and I presume Ruby) has lots of #3, complex data querying is not the most beautiful experience.