On Fri, Jan 2, 2009 at 2:52 AM, Cristiano Paris <frodo@theshire.org> wrote:
On Tue, Dec 30, 2008 at 8:35 AM, Conal Elliott <conal@conal.net> wrote:
>> Everything in Haskell is a function [...]
>
> Where did this idea come from?
>
> I'd say every expression in Haskell denotes a pure value, only some of which
> are functions (have type a->b for some types a & b).

Maybe more formally correct, but my statement still holds true as any
values can be tought as constant functions, even those representing
functions themselves.

Cristiano

I think most of the introductory material I've seen that made me go "aha now I get it" say pure functional programming is about values, and transformations of those values, and that functions are also values.  Then they usually go into admitting that that's only really good for heating up the CPU and that I/O and side-effects have to be made possible, but they're not willing to give up what they won for us by having everything be a value... then monads enter the discussion or "actions", and then monads get introduced later.



Dave
 

_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe