25 points · by omouse · 19y ago · 45 comments
Here's another my favorite, Erik on C++, from 1998: http://groups.google.com/group/comp.lang.lisp/msg/917737b7cc...
I'm pretty sure I'd feel dumber after having worked in PHP for the past six months on our new website, if that were true.
This guy is a little bit extreme.
Wrong. This reddit comment nailed it: http://programming.reddit.com/info/2mm0n/comments/c2mo30
Erik's argument is that Perl incentivizes The Wrong Way, and disincentivizes The Right Way. It's not about coercion, it's about incentives. "it's not that perl programmers are idiots, it's that the language rewards idiotic behavior in a way that no other language or tool has ever done." --jemfinch
Very concise. And it's always good to back it up with the assertions of some random dude on Reddit.
Someone (Perl) can be beautiful (Lisp features), but that doesn't change the fact that they wear dirty clothing (ugly syntax) and they smell kind of funny (ugly solutions).
It still is (excepting PHP)
The more I learn Lisp, the less it seems like Perl at all.
Scroll down to Appendix: Power.
The Perl solution is close to the Lisp solution in terms of brevity. The solution in other languages tend to be longer or the problem can't be solved at all.
Choice quote:
"In the rivalry between Perl and Python, the claim of the Python hackers seems to be that that Python is a more elegant alternative to Perl, but what this case shows is that power is the ultimate elegance: the Perl program is simpler (has fewer elements), even if the syntax is a bit uglier."
Here's a hypothetical Python:
mana=foo(100)
mana(-10)
mana(-15)
Here's Perl: $mana=foo(100);
&$mana(-10);
&$mana(-15);
Common Lisp: (setf mana (foo 100))
(funcall mana -10)
(funcall mana -15)
Also Common Lisp: (setf (symbol-function 'mana) (foo 100))
(mana -10)
(mana -15)
Just like how being surrounded by junk food predisposes you to poor dietary habits and possibly in consequence, heart problems, it's not impossible to eat healthy and stay fit.
Shunning the environment/language/tool is understandable, but equating it to the root of the problem always involves some exaggeration. The NASA code released not long ago had GOTOs in it and I don't think it costed lives.
His argument is that perl programmers are all busy solving immediate problems that would have never been problems to begin with if everyone had been using Lisp the way it was meant to be used. And they're often not solving problems in Lisp-fashion.
So pretty weak: CPAN is the supreme, far-and-away, no-other-reason-or-language-comes-close (at least in 2000) to use Perl.
I'm sure that there are areas where other languages' solutions are much cleaner than an equivalent perl one, but can anybody actually show us one? Especially a lisp one.
From the linked-to post: "...the language rewards idiotic behavior... you can commit any dirty hack in a few minutes in perl, but you can't write an elegant, maintainabale program..." Sound familiar? That's the mating call of statically typed language programmer and the top-down 'software architect'. That's bad. And I'll admit, Scheme's libraries (I use Scheme) are in practice somewhat statically typed and fussy, which sucks.
I've never used Perl - maybe I should. BTW, is Ruby really just as good for quick 'duct tape' work and hacks? My very limited experience with Ruby made me think it was good, but not extraordinarily handy.
One of the best programming quotes. Ever.
Jamie Zawinski's from 1997 is the most famous in modern times:
"Some people, when confronted with a problem, think "I know, I'll use regular expressions." Now they have two problems."
But, it dates back even further to a "D. Tilbrook" from before 1988:
"Whenever faced with a problem, some people say `Lets use AWK.' Now, they have two problems."
There's an XML variant that had quite a lot of popularity in the early 00's.
You've misunderstood the fundamental UNIX nature of these quotes. They are said by people who use the tools in question regularly. jwz doesn't avoid regular expressions for everything (he'd be a fool to do so, and he's no fool)...he's merely pointing out that regexes can be misused, and often are. Likewise Awk.
By cloistering yourself into Lisp, and nothing but, you're missing out on years of aggregate wisdom from some of the smartest people in computing. Lisp is one of those really valuable pieces of wisdom. But it is not the only one, or even the most important. Deny yourself the rest of the history of computing, and you are doomed to reimplement it...and you'll almost certainly do it poorly.