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 can also use arrow function in $callback parameter
This is N Log N time complexity. This task can be completed in N.
Duplicate issue, see jonesmat's post below. And you can still solve the problem (if your code handle that case):
"Too few arguments to function arr(), 0 passed in /workspace/default/tests/ExampleTest.php on line 10 and exactly 1 expected"
Error in tests, cant complete it;
There is no such input, the first value is what your function returned instead of the expected value. You're reading the error message wrong.
Very good kata, but for real, it isn't 7kyu.
This kata is a bit tricky, and I was surprised by the complexity for a 7kyu.
As mentioned by others below, this seemed too easy for 6 kyu Kata. Enjoyable, nevertheless.
Nice but kinda easy kata, consider making difficult version.