find numbers in array and print their sum javascript code example Example: js sum of array [1, 2, 3, 4].reduce((a, b) => a + b, 0) // Output: 10