Answers for "Two sets of parentheses after function call"

0

Two sets of parentheses after function call

function add(x){
  return function(y){
    return x + y;
  };
}

var addTwo = add(2);

addTwo(4) === 6; // true
add(3)(4) === 7; // true
Posted by: Guest on December-20-2020

Code answers related to "Two sets of parentheses after function call"

Code answers related to "TypeScript"

Browse Popular Code Answers by Language