Created
October 10, 2018 22:49
-
-
Save caseymorrisus/f8a103f06b7f1c8de4275f0e90eae243 to your computer and use it in GitHub Desktop.
Functional JS -- Not (!)
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 not = (x) => cond(FALSE)(TRUE)(x) | |
not(FALSE) // => TRUE | |
not(TRUE) // => FALSE | |
cond('Foo')('Bar')(not(TRUE)) // => 'Bar' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment