Can Your Programming Language Do This?

From the excellent programming blog "Joel on software", a very good text if you need to convince Java or C programmers that functional programming is a A Good Thing.
Probably all the readers of this list will find it brings nothing new (that's perfectly right) but it is oriented towards ordinary programmers :-) http://www.joelonsoftware.com/items/2006/08/01.html

On Wed, 2006-08-02 at 10:10 +0200, Stephane Bortzmeyer wrote:
From the excellent programming blog "Joel on software", a very good text if you need to convince Java or C programmers that functional programming is a A Good Thing.
Probably all the readers of this list will find it brings nothing new (that's perfectly right) but it is oriented towards ordinary programmers :-)
Curiously, I did something similar in my first year Haskell tute this week, which is the first week of semester (though I forgot to include the Swedish chef). My class studied C in the previous semester, so to motivate Haskell I got them to implement a polymorphic zipWith in C. I've put the tutorial on my web page in case anyone is curious: http://www.cs.mu.oz.au/~bjpop/ Under the heading: "433-152 (Zipping Lists)" Cheers, Bernie.

Read a sentence like this "If your programming language requires you to use functors, you're not getting all the benefits of a modern programming environment. See if you can get some of your money back." If this is not a very subtle pun (regarding Java functors vs. Haskell functors), which probably it isn't, then it is another indication of sloppiness in Joel's posts on the topic of MapReduce, which he is essentially alluding to in this new post, which in turn is meant to remind us of his earlier Java rant that was very much centered around MapReduce: http://www.joelonsoftware.com/articles/ThePerilsofJavaSchools.html. It may be Ok that MapReduce is a misnomer (because map and reduce sound so good; so I am not complaining so much about MapReduce's name), but I sort of dislike the idea of explaining map and reduce to "ordinary programmers" with examples that are *not* clear-cut forms of map and reduce. Just in case, it is not obvious anyhow: MapReduce's map and reduce are not (Lisp's or Haskell's) map and reduce: - http://www.cs.vu.nl/~ralf/MapReduce - http://blogs.msdn.com/ralflammel/archive/2006/06/19/637522.aspx Ralf (obviously in pedantic mode)
-----Original Message----- From: haskell-cafe-bounces@haskell.org [mailto:haskell-cafe- bounces@haskell.org] On Behalf Of Stephane Bortzmeyer Sent: Wednesday, August 02, 2006 1:11 AM To: haskell-cafe@haskell.org Subject: [Haskell-cafe] Can Your Programming Language Do This?
From the excellent programming blog "Joel on software", a very good text if you need to convince Java or C programmers that functional programming is a A Good Thing.
Probably all the readers of this list will find it brings nothing new (that's perfectly right) but it is oriented towards ordinary programmers :-)
http://www.joelonsoftware.com/items/2006/08/01.html _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

Hello Ralf, Wednesday, August 2, 2006, 1:27:39 PM, you wrote:
Read a sentence like this "If your programming language requires you to use functors, you're not getting all the benefits of a modern programming environment. See if you can get some of your money back."
in the article "history of Haskell" (announced by SPJ here) it was one brilliant phrase, what is 100% true for me - "Haskell jobs attracts most matured programmers". apart from Haskell, i almost don't know any language which is adequate to mindlevel of experienced programmer and allow me to think about functionality, about algorithms as opposite to implementation details and low-level code. and in particular, i hate repeating the same code more than one time and therefore i don't rate highly languages that don't allow me to use (and define) functors (it is not fair, but afair Joel is the man which worked in MS as programmer and as programmer's manager? i once reading his article which was started with statement "our (startup) firm requires the best programmer's talents" and in the middle he was written several examples of code which "best programmers" should be able to write, including such "complex" tasks as reversing linked list :) ) -- Best regards, Bulat mailto:Bulat.Ziganshin@gmail.com

So basically he rediscovered Why FP Matters
(http://www.math.chalmers.se/~rjmh/Papers/whyfp.html) ~15-20 years
after the fact, but neglected to point out the interesting fact that
one can write map in terms of reduce (i.e. foldr) (obviously he didn't
read the paper) and ignored the benefits of laziness. Also, if your
programming language has this ability and it's so great, why is this
not idiomatic? (i.e. people using for loops all over the place in
JavaScript).
(Sorry, couldn't find a place to comment on Joel's blog).
Jared.
On 8/2/06, Stephane Bortzmeyer
From the excellent programming blog "Joel on software", a very good text if you need to convince Java or C programmers that functional programming is a A Good Thing.
Probably all the readers of this list will find it brings nothing new (that's perfectly right) but it is oriented towards ordinary programmers :-)
http://www.joelonsoftware.com/items/2006/08/01.html _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
-- http://www.updike.org/~jared/ reverse ")-:"

I don't think this commentary is really fair. It's also insular and bad for the reputation of the Haskell community. There are enough barriers to exploring FP and Haskell already. The purpose of the article was to encourage people to start taking baby steps toward FP, not to demonstrate a deep mastery of the subject. Joel's blog is read by a wide range of technology people, most of whom have a principally OO background. Javascript was the obvious choice (it's more widely used than any other language with lambda nature). The word Functor is heavily overloaded in computer science. His use of the word is clearly a reference to the Functor Design Pattern and was appropriate for his readership. Sure, it's a long distance from the meaning of the word in category theory, but who really cares? I actually think that the appropriate paper to cite would be "Lambda: The Ultimate Imperative" by Guy Steele in 1976. It doesn't matter how old the academic literature is. If the lessons from the literature are not in widespread use, then it isn't a bad thing to try to popularize them. What he did at MS as a developer & development manager arguably made them a boatload of money. His own company seems to do quite well. All of this gives him high quality commercial credentials. An article in his blog can do a great deal to help FP (lazy or strict) be more widely appreciated. Reilly H. On Aug 2, 2006, at 11:14 AM, Jared Updike wrote:
So basically he rediscovered Why FP Matters (http://www.math.chalmers.se/~rjmh/Papers/whyfp.html) ~15-20 years after the fact, but neglected to point out the interesting fact that one can write map in terms of reduce (i.e. foldr) (obviously he didn't read the paper) and ignored the benefits of laziness. Also, if your programming language has this ability and it's so great, why is this not idiomatic? (i.e. people using for loops all over the place in JavaScript).
(Sorry, couldn't find a place to comment on Joel's blog). Jared.
On 8/2/06, Stephane Bortzmeyer
wrote: From the excellent programming blog "Joel on software", a very good text if you need to convince Java or C programmers that functional programming is a A Good Thing.
Probably all the readers of this list will find it brings nothing new (that's perfectly right) but it is oriented towards ordinary programmers :-)
http://www.joelonsoftware.com/items/2006/08/01.html _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
-- http://www.updike.org/~jared/ reverse ")-:" _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

I don't think this commentary is really fair. It's also insular and bad for the reputation of the Haskell community. There are enough barriers to exploring FP and Haskell already. The purpose of the article was to encourage people to start taking baby steps toward FP, not to demonstrate a deep mastery of the subject.
I feel (maybe others agree) delighted that someone so widely read begins to extoll the virtues of functional programming. I also feel (maybe others also agree) disappointed that this, and other such articles, fail to take the subject far enough, really showing what better programming languages can do. I supposed I should be happy; the long road to FP has to start somewhere, hopefully others will start down that road sooner rather than later. Jared.

He can't take it very far. The whole point is to keep the entire lesson in the space the audience regards as relevant. What you know to be relevant for his audience isn't the same as what his audience knows to be relevant. We are emphatically not the audience for this piece. Notice how he emphasizes the commercial value. My guess is that most of the people who participate on this list are in some sort of research center, where the value of academic research is a given. On Aug 2, 2006, at 12:32 PM, Jared Updike wrote:
I don't think this commentary is really fair. It's also insular and bad for the reputation of the Haskell community. There are enough barriers to exploring FP and Haskell already. The purpose of the article was to encourage people to start taking baby steps toward FP, not to demonstrate a deep mastery of the subject.
I feel (maybe others agree) delighted that someone so widely read begins to extoll the virtues of functional programming. I also feel (maybe others also agree) disappointed that this, and other such articles, fail to take the subject far enough, really showing what better programming languages can do. I supposed I should be happy; the long road to FP has to start somewhere, hopefully others will start down that road sooner rather than later.
Jared.
Reilly Hayes rfh@reillyhayes.com

On Wed, Aug 02, 2006 at 01:02:20PM -0700,
Reilly Hayes
My guess is that most of the people who participate on this list are in some sort of research center, where the value of academic research is a given.
As someone who does not work in a research center, and who tries to use Haskell for practical problems, I can say that I have mixed feelings about haskell-cafe: 1) My newbie questions always receive a timely answer, the answer is correct and the tone of the reply is friendly without any sign of patronization against the beginner. (Same thing on #haskell, so it is a good opportunity to thank everybody.) 2) The typical discussion and the typical subjects are very far from the ordinary programmer. If he or she reads the archives of the list before commiting herself or himself to Haskell, he or she might be scared.

On Wed, Aug 02, 2006 at 11:14:30AM -0700,
Jared Updike
(Sorry, couldn't find a place to comment on Joel's blog).
http://discuss.joelonsoftware.com/?joel And I agree with Reilly Hayes: as I said in my first message, Joel tried to introduce ordinary programmers (not computer-science teachers) to functional programming. Such propaganda work is extremely useful and experts in monads or type inference may not be the best people to do so.
participants (6)
-
Bernard Pope
-
Bulat Ziganshin
-
Jared Updike
-
Ralf Lammel
-
Reilly Hayes
-
Stephane Bortzmeyer