in reply to Re: Resources for Functional Programming?
in thread Resources for Functional Programming?
For example, just about everything that had to do with a user interface. Printing text is a "side effect" (or in your Haskell terminology, probably seen as a monad). Asking a user a question. Responding to the user's input.
The big problem in Prolog with such constructions was that Prolog's whole view of the world was that you could search a database of rules and backtrack as necessary. But with monadic tasks, you really don't want any backtracking. You don't want to pop up a dialog on the user's screen, wait for an answer, and then backtrack (possibly trying a different dialog box) when you realize that the user's answer didn't get your program any closer to a "solution."
--
[ e d @ h a l l e y . c c ]
|
|---|