by lmm · 13y ago · 0 comments
>[The 911 is] so obviously superior to the Cadillac that a child could tell it's better.
My first thought was that the Cadillac looked better even though the internals of the 911 were certainly higher quality. Does that mean I have worse design sense than a child? :(
>The Cadillac was carefully designed to appeal to the average driver. The 911 was designed for performance. Which one is better design?
It all depends on how you evaluate quality: there are so many ways to determine the "best" that questions like this are almost meaningless.
Regardless of the car metaphor, I think PG's point makes a lot of sense.
Does it?
From the article: C, Smalltalk, Lisp. The languages that were consciously designed for "average" programmers (Cobol, Pascal, Ada) have tended to be evolutionary dead ends.
COBOL and Pascal (via Delphi) are probably used more than Smalltalk and Lisp in the real world. Also, Java and C#, designed for the 'average' programmer, are immensely popular outside our little bubble. Java has been around for twenty years and will probably be for at least two more decades.
I like tinkering with new and 'revolutionary' languages - I wrote a fair share of Prolog and Haskell, but I have come to the realisation that that I like to solve interesting problems (mostly in NLP and machine learning) far more. And when you focus on solving an interesting problem it can be good that the language and ecosystem are boring and predictable (Java, C, C++), so that you can focus at the problem at hand. For example, in Java you can easily add a library to a project via Maven and its usage will often be completely predictable, you don't have to deal with the fact that the library writer was in an existential typing, GADT, or arrows phase and fight with its API.
BTW. I still love Prolog and Haskell ;).
I've found that the advantages of using a nice high-level language like Haskell far outweigh issues with build systems and libraries and the usual boring stuff Java et al are supposed to excel at. This for very interesting problems--most recently, program synthesis using MCMC. (Following the "Stochastic Superoptimization" paper, but I honestly think that name is a bit silly :P.)
Besides, have you ever tried to use the equivalent of Parsec or QuickCheck in Java? Even boring, practical things like that are better in Haskell!
Sure, Java is inelegant and dirty, but you don't have to perform the thinking needed to write a dissertation to use it.
The amount of type wizardry that Haskell permits is far larger than Java and C++ teaches us that in practice you have to expect all possible combinations language features that are allowed. A random Java library will have a far more understandable API than a random Haskell package, since there are not so many permutations of language features possible.
If everybody stuck to just Haskell 98, things would be far simpler.
Besides, have you ever tried to use the equivalent of Parsec or QuickCheck in Java?
As a matter of fact, I just committed QuickCheck-like unit tests five minutes ago [1] :):
https://github.com/danieldk/dictomaton/commit/7aaa89aae68524...
I write such tests in Java quite often. Of course, you don't have the nice combinators of QuickCheck :). I am not saying that Haskell isn't more powerful it is. But it comes at a cost: many packages come with an up-front learning cost, Haskell is hard to optimize compared to Java or C, etc. The Java APIs are predictable, run-time performance is predictable (in the sense that it easy to profile and optimize) and the ecosystem is boring and predictable. These are some of reasons that Java is popular (besides having a steward with deep pockets).
([1] Ps. yes, I know there is a very obvious optimization optimization possible that commit, it's a development branch.)