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.
Does one of the test cases consider if the two pieces are occupying the same space? Like a Game has been finished? In that case should it return "King" or nothing?
This description is really hard to understand for me.
I don't understand what we are trying to do here, or even what terms to look up to figure this out.
Normally I can just figure out what the pattern is from Test Cases, and recreate it, but even that fails me here. Can anyone help me get started?
Why does |i| in your function return the index? I thought it was necessary to use "with index", and pass two arguments to get the index value.
I like how this looks.
Or you could do what I did, and just hit submit a bunch of times.
I passed the random tests on attempt #4 with the same error. And I didn't even need to fix my code!
If there was a "best practices", "clever", and "visually appealing" category this would get my vote for "visually apealing".
How does the || s < "5" || part work if 5 was a string and not an integer?
Can the less than (<) operator read strings?
At first I was like... "Dude are you ok?"
Then I saw the random tests part and was totally relived.
It may not "belong" with the other 8 kyu's, but the fact that it is actually helps people solve it. If this was placed at a 6 kyu I would have gone down a very differnt path to find the answer. So I'm fine with 8 kyu because of the extra clue it provides.
I've completed 228 Kata's on this site, and this is the FIRST time I have been asked to raise and error inside of a function. I think that adds a little bit of uniquness to this Kata and separates it from the myriad of Regex problems.
If you have two nested while loops, your solution will time out. This kata is a test of your ability to optimize the problem into a single loop.
Thank you! That was the hint I needed to figure it out.
This comment is hidden because it contains spoiler information about the solution
Had the same issue. Only time I have ever seen this problem on CodeWars. Kata should be removed until this is fixed.
I submitted that as answer and it just went through.
Loading more items...