TY - BOOK

T1 - The Haskell Programmer's Guide to the IO Monad

T2 - Don't Panic

AU - Klinger, S.

N1 - Imported from CTIT and EWI/DB PMS [db-utwente:tech:0000003696]

PY - 2005/11

Y1 - 2005/11

N2 - Now, that you have started with Haskell, have you written a program doing IO yet, like reading a file or writing on the terminal? Then you have used the IO monad—but do you understand how it works? The standard explanation is, that the IO monad hides the non-functional IO actions —which do have side effects— from the functional world of Haskell. It prevents pollution of the functional programming style with side effects. However, since most beginning Haskell programmers (i.e., everyone I know and including me) lack knowledge about category theory, they have no clue about what a monad really is. Nor how this “hiding��? works, apart from having IO actions disappearing beyond the borders of our knowledge.
This report scratches the surface of category theory, an abstract branch of algebra, just deep enough to find the monad structure. On the way we discuss the relations to the purely functional programming language Haskell. Finally it should become clear how the IO monad keeps Haskell pure. We do not explain how to use the IO monad, nor discuss all the functions available to the programmer. But we do talk about the theory behind it.
Intended audience: Haskell programmers that stumbled across the IO monad, and now want to look under the hood. Haskell experience and the ability to read math formulae are mandatory.

AB - Now, that you have started with Haskell, have you written a program doing IO yet, like reading a file or writing on the terminal? Then you have used the IO monad—but do you understand how it works? The standard explanation is, that the IO monad hides the non-functional IO actions —which do have side effects— from the functional world of Haskell. It prevents pollution of the functional programming style with side effects. However, since most beginning Haskell programmers (i.e., everyone I know and including me) lack knowledge about category theory, they have no clue about what a monad really is. Nor how this “hiding��? works, apart from having IO actions disappearing beyond the borders of our knowledge.
This report scratches the surface of category theory, an abstract branch of algebra, just deep enough to find the monad structure. On the way we discuss the relations to the purely functional programming language Haskell. Finally it should become clear how the IO monad keeps Haskell pure. We do not explain how to use the IO monad, nor discuss all the functions available to the programmer. But we do talk about the theory behind it.
Intended audience: Haskell programmers that stumbled across the IO monad, and now want to look under the hood. Haskell experience and the ability to read math formulae are mandatory.

KW - METIS-226143

KW - IR-53411

KW - EWI-7664

M3 - Report

T3 - CTIT Technical Report Series

BT - The Haskell Programmer's Guide to the IO Monad

PB - Centre for Telematics and Information Technology (CTIT)

CY - Enschede

ER -