Course · Section 17: Modern JavaScript Development: Modules, Tooling, and Functional · Lecture 294: Declarative and Functional JavaScript Principles
Implement `declarativeSum(nums)` returning the total using `reduce` (a declarative style) rather than an imperative loop.
+ 1 hidden test run on Submit.
reduce declares the aggregation directly, a more functional style than a manual loop.
Run your code to see results.