You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I had the same result. It took me a while to figure it out.
The expected output is using the implementation of the reduce function from exercise 16, which returns an array of accumulated values. You are using the standard reduce method from the Array.prototype object in Javascript, which only returns a single accumulated value. To get the desired output just add reduce implementation from exercise 16 to the Javascript Array.prototype.
If I console.log() the result of this exercise, it is not like the expected one:
it looks like this:
Is the expected output wrong or just the solution?
Thanks for the great Exercises at all.
The text was updated successfully, but these errors were encountered: