Skip to content

Instantly share code, notes, and snippets.

@jjant
Created June 14, 2018 20:10
Show Gist options
  • Save jjant/c8c17ff151e131cf46b9be801f948fa5 to your computer and use it in GitHub Desktop.
Save jjant/c8c17ff151e131cf46b9be801f948fa5 to your computer and use it in GitHub Desktop.
myCont = Cont (\k -> k 0 + k 15)
runCont myCont id -- id 0 + id 15 = 15
myCont2 = myCont >>= (\x -> Cont ($ (x * 2))
runCont myCont2 id -- 30. Wait, what?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment