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.
my apologies - misread the description
This comment is hidden because it contains spoiler information about the solution
Well, in any case I'll re-raise this issue. Resolve it after you've fixed your tests.
It wasn't unsolvable, but considerably harder. I really think you should create that kata. :-)
Thanks again!
The issue is not resolved.
If some solutions fail against some test cases, then they should not pass. If you're still allowing them to pass, it's an issue, the kata is bad and you should feel bad. You might as well write no tests, since you're now literally saying correctness is not your concern. Tests are what enforces and validates your specs, and it's your responsibility as a kata author to write thorough and complete tests.
Also, have you actually run the solutions against these edge cases? Because I only raised this issue after checking lots of existing solutions.
(Also, given that this kata is
5kyu
, these things are kinda mandatory for this ranking. Otherwise it should be downranked to6kyu
, or even7kyu
.)You are correct in that some languages have insufficient tests and that there are solutions taking advantage of that.
However, I think most solutions will pass all of your edge case tests.
The group that would benefit most from more edge cases is the people who wanted to write a "proper" solution, but happened upon a "wrong" solution that solved the test cases. There are a few of these, but I doubt there are very many.
If you give me the above cases as tests, I'll paste them into the existing tests.
When it comes to longer strings, I will not put in these tests here. Adding them would make the kata significantly more difficult (perhaps unsolvable?) and since the kata has already been graded, it would not be fair. But feel free to create a new, "Harder String Merge" kata. It would be fun trying to solve it. :-)
I'm honoured that you care enough about this kata to evaluate the existing solutions and I agree that the kata was published before the tests were properly reviewed (one downside of communal responsibility, I guess). Even so, I will remove the "issue" tag, because of what I wrote in the description: "figure out the rest from the given test cases". The existing test cases are the specification.
This comment is hidden because it contains spoiler information about the solution
These tests fail on Javascript when they shouldn't:
codewars can't be created from code and wasr
codewars is not a merge of cwdr and oeas