Easy
JavaScript: Understanding Chained Array Methods with Map, Filter, and Reduce Operations
What will be the output of the following code, and why?
1let numbers = [1, 4, 7, 10];2let base = 5;34let result = numbers5 .map((num, i) => i % 2 === 0 ? num * base : num - base)6 .filter(num => num % 2 === 0)7 .reduce((sum, num) => sum + num, base);89console.log(result);