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.
You mutated the original array, so there's nobody but you to blame for! :)
Yeah, the JS one is busted for me.
Yep! It's working fine now. Thanks!
I think I fixed it, but I haven't tried. Could you have a look at the JavaScript tests and resolve the issue if they're fine?
Yep, it was the JS version! Thanks very much!
The random tests in the Javascript kata seem to think that >8 is the correct result, as noted by the expected [90, 8] being listed as Open, instead of the Actual case of Senior.
Hey I'm having the same issue as the person below. Everything passes except for 'Random Tests. They should work but it says all expected answers is '1'.
Testing for for gimme([-67, -93, -82])
Must work for random arrays too - Expected: 1, instead got: 2
For Javascript, all random solution tests search for 1 being the answer, which means that the solutions fail because the random lists are actually sorted to find the answer, without leaving a reference list that remains unsorted. The javascript sort function changes the original array, so without creating a copy, you accidentally leave a sorted array to be compared with the unsorted array.
EDIT: Here's some example solutions that were tested and considered failed.