Created
August 29, 2019 08:33
-
-
Save Lily-La-Day/ef4b1dce75225b7ee9db7466f17b5afa to your computer and use it in GitHub Desktop.
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
//curried | |
function add (a) { | |
return function (b) { | |
return a + b | |
} | |
} | |
add(3)(4) | |
const add3 = add(3); | |
add3(4) | |
//un-curried | |
function add (a, b) { | |
return a + b | |
} | |
add(3, 4); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment