The reduce method applies a function against an accumulator and each element in the array to reduce it to a single value.
Source Code
let numbers = [1, 2, 3, 4, 5];
let sum = numbers.reduce((acc, current) => acc + current, 0);
console.log(sum); // 15