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.
Genius!
This comment is hidden because it contains spoiler information about the solution
I think so!
dope
I like this solution the most. Very easy to read!
You don't need both 'return 1;' statements. If you have two or more case statements in a row with no return or break statement, the next statement will handle those cases together. In other words:
case 1:
case 2: return 1;
functions the same as:
case 1: return 1;
case 2: return 1;
I agree - so clever!
I think it's clearer.
My fav solution!
I guess if you were to use this in a browser environment without a transpiler you might want to use the array notation.
This comment is hidden because it contains spoiler information about the solution