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 believe the variable
r
can be quiet large and will take over 6000ms to complete whenr
is large for multiple tests. So in other words, your solution isn't efficient enough to complete this kata in the required time boundaries. You may want to rethink your stratergy.This comment is hidden because it contains spoiler information about the solution
you have an infinite loop somewhere. You need to recheck your code and make sure there are no loops, this isnt an issue with the kata and should therefore resolve the issue. :)
My code doesn't pass test 4, 7, 8, 9, 11, 12, 13, 14. The first error is: "Expected: Leonard, instead got: Penny". This seem to happen due to the names array input stacking up all the names as a global variable. I then tried to declare a copy of it to a new variable, and refer to that copy while running my function. Same problem persist. Finally - I made a raw copy of the names array and put it in my code. It now passes all the tests, but instead I'm getting an error saying "Process was terminated. It took longer than 6000ms to complete". Can someone please help me explain what's going on?
I'm using JavaScript.
Thanks in advance!