Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
real🤣
Next level dedication
Mad late, but hopefully helpful to future users: 0 is the initial value in the .reduce() method. As imaNami above said - it's totally optional and the code will still work without it.
Clean🔥
Years late, but this advice is solid! Love this convo and the web dev community
Awesome that makes a lot more sense, thank you!
This comment is hidden because it contains spoiler information about the solution
Tad bit late on this, but hopefully helpful for future users:
The way this function is written is in the arrow function form but it's ultimately the exact same thing as doing the regular function declaration form that you wrote. Just returns 1 line instead and makes the code look more clean.