Welcome! and rules
Joel on Software
C# vs Perl text processing performance
I've been comparing C# with Perl for a high volume intensive text processing application: take a list of phrases, and for each one exclude noise words, stem individual words back to root forms, and write all combinations of words from each phrase (sorted alphabetically) to a text file. This is textbook Perl stuff, but to my surprise I found that the C# version of my code ran about 20% faster than the Perl version. They do essentially the same thing, and generate identical output files.
I'm not at all surprised by this. PERL is insanely dynamic language and C# is reality static. PERL is interpreted. C# is compiled at runtime (from byte-codes to native code). C# has proper string handling unlike it's cousins C and C++ to which PERL's text processoring is often favourably compared with.
I dunno, I think this is actually an endorsement for Perl.
> C# has proper string handling unlike it's cousins C and C++
Whoa. Which perl were you using?
Fog Creek Home