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.
Look at the line of code where you get an error and try to debug.
No. All works and worked fine. But random tests sent an array first to your kata and then to my solution. So when you broke data in the array in your solution, then that broken one was sent to my solution. And the result was random.
OK. I modified kata and it creates a copy of array before it's sent to the solution. I hope it solved your issue ;)
Nope. It works fine. It doesn't leak. I have just checked it. It's a javascript. Maybe you are modifing input data and your code breaks kata itself. Don't modify input.
It looks like it leaks for me. it leaks in 2 places even. You were lucky that your solution passed random tests.
You need to do a deeper analysis of the group, it is not enough to take the most popular letter of the group and assume that it was encoded with the letter "E" (this does not always work). Look at it this way - each group is encrypted with the Caesar cipher and for that group you need to understand what shift was used in its encryption. By analyzing the shift - you can find the correct letter.
As akar-0 points out it is a valid JavaScript variable name (in fact there's a couple popular libaries built around it), but the convention originated in some other language (or perhaps even a linter?) to use
_
as a shorthand for "this argument isn't used".Yes. Its value is not actually used so there's no need to declare it with a handy name (though we could use _ as a variable name in JS).
I dont get the rules then lol. If you go NORTH, WEST, SOUTH AND EAST , I end up in the same point I started. Are the directions in a global coordinate or they are relative to the guy walking?
MORSE_CODE
is the dictionary name, you don't need to import it.It's the first one in the description's note.
Correct, but this kata works with different rules. See description for this exact case and clarification.