Skip to content

Instantly share code, notes, and snippets.

@michaelt
Created December 5, 2016 09:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save michaelt/c9abe9139d5ea9bf6a6b366d2fc90010 to your computer and use it in GitHub Desktop.
Save michaelt/c9abe9139d5ea9bf6a6b366d2fc90010 to your computer and use it in GitHub Desktop.
import Control.Concurrent (threadDelay)
import Control.Concurrent.Async (race)
import Control.Monad
marika = forever $ do
threadDelay (10^6)
putStrLn "Marika Boo!!!"
s = do
c <- getChar
case c of
's' -> return ()
_ -> s
main = do
s
race marika s
return ()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment