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.
can you explain why using $ as variable name? does it have any significance in dev world?
avoid using "var" keyword, instead use "let"
как проходит твой день
ноу, ю
better not to change the buildin keywords
👍
Mine is similar, with a little tweak on checking if there's no matched return
This comment is hidden because it contains spoiler information about the solution
very nice.. I did 10/15 lines to did the same thing...
return arr.join(' ') === '' ? null : arr.join(' ');
return arr.join(' ') ? arr.join(' ') : null;
return arr.join(' ') || null;
A couple ways to refactor your return statement. An empty string in JS is a falsy value, so you can just check the boolean value of the string.
wow cool happy xmas
simple
Because he can do it, naming function's arguments whatever he wants. JS allows it
Great solution and almost exactly the same as the one I wrote. Only catch would be if a number instead of a string was passed.
👏🏼 but
el = 'U' is unnecessary
Loading more items...