Created
February 11, 2018 16:13
-
-
Save davidbarral/0b8dee173113faaaada1c0824fc6c5a3 to your computer and use it in GitHub Desktop.
Curry: not working version
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
const curry = fn => (...args) => | |
args.length >= fn.length | |
? fn(...args) | |
: curry((...innerArgs) => fn(...args, ...innerArgs)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment