--- id: 5e302e80e003129199103c78 title: Part 21 challengeType: 0 isHidden: true --- ## Description
To track how the `reduce()` function works, log the values of the `accumulator` and `currentValue` in the callback function before the `return` statement like this: `console.log({ accumulator })` You can also check your progress by adding `console.log({ total })` at the end of the `calculate()` function. When you enter calorie values in the form and push the Calculate button, you will see the values of `accumulator` and `currentValue` in each iteration of the `reduce()` callback function.
## Instructions
## Tests
```yml tests: - text: See description above for instructions. testString: assert( code.replace(/\s/g, '').match(/console.log\({accumulator}\)/) ); ```
## Challenge Seed
```html ```
### Before Test
```html

Calorie Counter

Sex
Breakfast
Lunch
Dinner
```
### After Test
```html ```
## Solution
```html ```