Javascript - .reduce
\nconst numOfPairs = (nums, target) =>\n  nums.reduce((a, c, i, arr) => {\n    for (let j = 0; j < arr.length; j++) {\n      if (j === i) continue;\n      if (c
```\nconst numOfPairs = (nums, target) =>\n  nums.reduce((a, c, i, arr) => {\n    for (let j = 0; j < arr.length; j++) {\n      if (j === i) continue;\n      if (c + arr[j] === target) a++;\n    }\n    return a;\n  }, 0);\n```
['JavaScript']