C# vs. VB
Rowan about C# vs. VB:
> None, if challenged, would be able to build anything using
> C# that Phil couldn’t build just as well in VB.
This isn’t the point. Different languages have different levels of expressiveness and also different aesthetics. A program written in Haskell may be 10 times shorter than the same program written in C++ for example [1].
Personally, I have two favourite languages: Ruby and Haskell :-)
In Ruby I can write this:
10.times { |i| puts i }
But in C# I have to write this:
for (int i = 0; i < 10; i++) { Console.Write(i); }
Which do you find more beautiful? :-)
1.
Trackbacks
Use this link to trackback from your own site.
Using C# 3.0 you could do something like this:
5.Times( i => Console.WriteLine(i) );
James… that is exactly what I just wrote up…
Yep, Lambdas are a good thing and I wonder sometimes why we had to go through the “delegate” syntax to get there.
php ftw:
echo implode(range(1,10));
you could also one line your C#
for (int i = 0; i
[...] Andrew from Mindscape makes the point that every different language has “different levels of expressiveness and also different aesthetics.” [...]
Extension methods for a rubyish like library