> What about the "all pure functions" part? By definition, pure functions don't have side effects, right? (A side effect is when a function changes some state outside the function itself, like a global variable or the file system.) So…how can these functions be pure if all this I/O is happening?
> It's surprisingly simple:
> Each function returns a value describing what I/O it wants done.
> The compiled program has a runtime which looks at those values and actually performs the I/O they describe.
So... like the IO monad.