Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on May 23rd, 2012  |  syntax: None  |  size: 0.20 KB  |  hits: 14  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. function add(a, b, c, d) {
  2.   return a + b + c + d;
  3. }
  4.  
  5. curry(add)(1)(2)(3)(4); // perfect, right?
  6. curry(add)(1)(2)(3,4);  // works just as well
  7. curry(add)(1,2,3,4);    // that's no currying there, right?