Let\'s say I have some function:
function g(a,b,c){ return a + b + c }
And I\'d like to turn it into its \"curried\" form (in quotations si
Please check the curry library.
It can turn any function into curry no matter how many arguments are there.
Example:
> var curry = require('curry');
undefined
> var add = curry(function(a, b, c, d, e) { return a + b + c + d + e; });
undefined
> add(1)
[Function]
> add(1,2,3,4,5)
15
> add(1,2)(3,4)(5)
15
>