You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
constmultiArgFunction=(a,b,c)=>a+b+c;console.log(multiArgFunction(1,2,3));// 6constcurryUnaryFunction=(a)=>(b)=>(c)=>a+b+c;curryUnaryFunction(1);// returns a function: b => c => 1 + b + ccurryUnaryFunction(1)(2);// returns a function: c => 3 + ccurryUnaryFunction(1)(2)(3);// returns the number 6
手写柯里化函数
干净版本:
es6实现:
带占位的封装
羽哥:
高颜值写法:
The text was updated successfully, but these errors were encountered: