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.
This is where the cumulative value produced by the reduce method is returned. If you used the reduce function without a return, you'd have nothing to show for your efforts.
Just too easy, even for an 8kyu.
Need random tests.
[ 7, NaN, -7, "asdfad", 1.4545454545454546, 0.23529411764705882 ]
It should work for random inputs too - Expected: NaN, instead got: false
However, the instructions clearly state that false is expected. Trying to work around this bug is problematic. For the random tests, if you have a NaN and another invalid entry in the same array, it's purely random as to which appears in what order, and what the test expects (false vs. NaN).
too easy, needs a twist, even for an eight
"In this Kata you will ... returns a flat list." However, the test requires that a list within a list be returned. So, isn't that returning a one-deep list?
too easy
The testing has no relationship to the the instructions. It seems that the author accidently published this as beta. As it is now, it should be removed, until ready.
By chance, the only valid inputs (that break with the bug), are stings with length of two. So, I basically reassigned the pound sign as such:
(n.length===2) ? m=n.slice(1)+"P" : m=n;
Took a bit of work to overcome the an encoding bug related to the pound sign.
Helps to read the tests to understand what this kata requires, otherwise you might be scratching your head a bit (like I did).
Doesn't make sense to restrict this ES6 kata to Node 0.10.33, unless the point is to refactor the starter code to pre-ES6 code... but then, is the opposite of the kata description.
Without requiring the use of split, map, ets., this seems like a level 8 kyu.
The edge case of a generator takes this above the 8kyu level.