[Haskell-cafe] Functional vs Imperative

Wolfgang Jeltsch wolfgang at jeltsch.net
Tue Sep 13 11:57:41 EDT 2005

Am Dienstag, 13. September 2005 15:45 schrieb Dhaemon:
> [...]

> Also, just for kicks, may I had this: I read the code of some haskell-made
> programs and was astonished. Yes! It was clean and all, but there were
> "do"s everywhere... Why use a function language if you use it as an
> imperative one?(i.e. most of the apps in http://haskell.org/practice.html)

Note that do expressions are not expressions whose evaluation has 
side-effects.  The evaluation of a do expression doesn't yield the result of 
the action it describes, causing side-effects, but it yields the action 
itself.  Evaluation of this action is done seperately.

> Thanks in advance,

Best wishes,

More information about the Haskell-Cafe mailing list