The monad of Suspended computations

A discovery: input events are clearly an example of interacting with the
outside world, but surprisingly, waiting for the next event doesn't have
to use the IO monad!

The Suspend monad allows a pure computation to be halted while waiting
for a pending event to occur. The idea is that this pure computation
would be executed by an IO wrapper which resume suspended computations
by sending it the actual events.
Demo: how to feed a suspended computation

Repeatedly capture events and send them to the suspended computation.