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.
I am not completely sure why there are curly brackets and plys inside but i know rest. So this regex will try with match method to match all odd OR even numbers from num(which will be always num because here we passed if/else with ternary operator) and then match is returning array of matched elements, so at the end he is passing join() method with '-' as with what to join them.
Got 'er done, anyway (with plenty of ES6, to boot).
Did MVD (Minimum Viable Debug). 10 seconds.
Nice:
switch (true)
so you can evaluate inequalities (even if not efficient).This comment is hidden because it contains spoiler information about the solution
Lot of lines, but hopeflly easy to follow, even for new beginners.
Was in a bit of a rush. And, what do you know, it shows! At a minimum, I would change the name of 'interim' to 'resultsArray' and 'let' to 'const'.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Refactored:
Nice!
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Loading more items...