Skip to content

Instantly share code, notes, and snippets.

@jutememo
Created May 4, 2011 06:28
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 jutememo/954835 to your computer and use it in GitHub Desktop.
Save jutememo/954835 to your computer and use it in GitHub Desktop.
concat'cps [] k = k []
concat'cps ([]:_) k = []
concat'cps (xs:xss) k = concat'cps xss $ \xss' -> k $ xs ++ xss'
main = print $ concat'cps [[1,2],[3,4],[],[5,6]] id
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment