Created
November 17, 2016 22:29
-
-
Save markmur/c5344b023639b3b46c4899e4fc405df4 to your computer and use it in GitHub Desktop.
Recursive Curry Add
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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