diff --git a/calculator/calculator.js b/calculator/calculator.js index 2e08f49..fe548f7 100644 --- a/calculator/calculator.js +++ b/calculator/calculator.js @@ -7,7 +7,7 @@ function subtract(a, b) { } function sum(array) { - return array.reduce((current, total) => total + current, 0); + return array.reduce((total, current) => total + current, 0); } function multiply(array) {