[Haskell-cafe] Elevator pitch for functional programming
Adrian Neumann
aneumann at inf.fu-berlin.de
Tue Jan 20 07:40:41 EST 2009
There was a thread about that:
> http://www.haskell.org/pipermail/haskell-cafe/2007-September/
031402.html
Am 20.01.2009 um 11:07 schrieb Jim Burton:
> Hi, I will be a TA on a comparative PL course and I'm looking for
> small examples (ammunition) which motivate the use of Haskell and
> functional programming generally. The course is for 1st year Software
> Engineers, none of whom are likely to have used a functional
> language. They will all have experience programming Java and a little
> C++, with a few of them knowing Python, Ruby, PHP etc etc too.
>
> If anyone has code snippets which are the equivalent of an elevator
> pitch for FP, I would be very grateful to see them. What I want
> are some small concrete examples of idioms which are natural and
> powerful in Haskell but difficult or impossible in, say, Java.
>
> So I can produce examples of some of the things that make FP powerful,
> elegant, expressive etc: higher order functions, polymorphism,
> composition (ask them to write (.) in Java :-)), partial application
> and so on. I will point any interested souls to Hughes' great paper
> [1]. But I have little time and it might be hard to put across why
> they would want to do these things in the first place. I was looking
> for something that speaks directly to the kind of problems they face
> in languages like Java...
>
> Types are a good example because Java programmers generally already
> appreciate the help they get from compiler messages etc, so you can
> sell a more flexible, enhanced form of this. Purity might appeal to
> anyone who has longed to be able to reason about nastily complex code
> with a lot of shared state. Laziness, streams? Hard to do in Java (I
> presume) but also quite hard to sell the need.
>
> The existence of an O'Reilly book will help, especially one that can
> be sampled online, so I'll point them at RWH for extended concrete
> examples. They will need to be already sold before they will bother
> with that though.
>
> Thanks,
>
> Jim
>
> [1] http://www.cs.chalmers.se/~rjmh/Papers/whyfp.html
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 194 bytes
Desc: Signierter Teil der Nachricht
Url : http://www.haskell.org/pipermail/haskell-cafe/attachments/20090120/5aef1ec3/PGP.bin
More information about the Haskell-Cafe
mailing list