Skip to content

Instantly share code, notes, and snippets.

@markmur
Created November 17, 2016 22:29
Show Gist options
  • Save markmur/c5344b023639b3b46c4899e4fc405df4 to your computer and use it in GitHub Desktop.
Save markmur/c5344b023639b3b46c4899e4fc405df4 to your computer and use it in GitHub Desktop.
Recursive Curry Add
function add(x) {
var fn = (n) => add(n + x);
fn.toString = () => x;
return fn;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment