Skip to content

Instantly share code, notes, and snippets.

@davidxifeng
Created May 19, 2013 07:13
Show Gist options
  • Save davidxifeng/5606948 to your computer and use it in GitHub Desktop.
Save davidxifeng/5606948 to your computer and use it in GitHub Desktop.
haskell ADT
c = let x = 0 : y
y = 1 : x
in
x
-- c [0,1,0,1...]
-- 这种技巧是用来使用data来实现图,双向链表等结构的
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment