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.
Merged, and arrow functions seem to work now.
The kata is currently in version
7.0
but arrow functions were introduced in7.4
.I made this fork updating the kata to version
8.0
. Please review before approving, this the first time I do php.Remember: this is Codewars. Here, readability goes out the window.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Could you provide the issue you're encountering ? We can't help you if we don't know what's the error.
(I won't be able to help you as I didn't solve but others will if they have all the information)
Not sure if someone is still working on the kata.
Had an issue pop up with some of the PHP test cases. Doesn't seems to be an issue on my side.
The code runs fine in my IDE but I get "undefined array key" in the test case file when running the code on CW.
Let me know if other people are experiencing the same thing and if I maybe need to have a look at my code again (:
Go look up sliding puzzle and how inversions play a role. If a certain amount of numbers are "out-of-place" the puzzle becomes unsolvable.
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
Definitely not the most efficient way.
But still clever.
Practically, don't think this will ever need to be scaled. It's tic tac toe. If possible future scaling isn't an issue, why even bother future proofing it?
This might be a very simple function, but it's basically unreadable. Makes maintaining a codebase a lot harder. Same function just with more descriptive variable names and a comment or two and you should be set.
Shorter does not always equal better.
The whole idea is having a class and a constructor for multiple people, eventually being able to scale with more parameters and methods. This solution is not only unreadable, but makes it diffucult to scale.
you're right. but this programming is for fun, not real development. no one writes this in an important part of the real project
Loading more items...