Skip to content

Instantly share code, notes, and snippets.

@louisrli
Created April 15, 2013 18:45
Show Gist options
  • Save louisrli/5390343 to your computer and use it in GitHub Desktop.
Save louisrli/5390343 to your computer and use it in GitHub Desktop.
Try putting this in the OCaml toplevel ;) Credits to Pierce p. 334
let f0 = fun x -> (x, x) in
let f1 = fun y -> f0 (f0 y) in
let f2 = fun y -> f1 (f1 y) in
let f3 = fun y -> f2 (f2 y) in
let f4 = fun y -> f3 (f3 y) in
let f5 = fun y -> f4 (f4 y) in
f5 (fun z -> z);;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment