Skip to content

Instantly share code, notes, and snippets.

@avoidwork
Created April 4, 2017 12:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save avoidwork/541cd55af878b0ded4097415e5220472 to your computer and use it in GitHub Desktop.
Save avoidwork/541cd55af878b0ded4097415e5220472 to your computer and use it in GitHub Desktop.
Curry example
function curry (fn, ...x) {
const lfn = fn.apply(fn, x);
return function (...y) {
return lfn.apply(lfn, y);
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment