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.
mocha + chai
should be enabledMissing edge cases like this which will invalidate a lot of solutions (including top-voted one)
Description does not mention how to handle cases when the key is not found in the given object
This comment is hidden because it contains spoiler information about the solution
Could you add a C# version to this kata? Already solved it there before seeing that there was no C# option lol
tests need to be much more torough regarding randomness, and assertions should be improved (
test.expect
is used in JS and Python)Seems like an issue with the junit tests at first sight.
src/test/java/TestSuite.java:54: error: incompatible types: Test cannot be converted to Annotation
@Test
^
src/test/java/TestSuite.java:63: error: incompatible types: Test cannot be converted to Annotation
@Test
^
2 errors
it is not specified what to do when there are duplicate elements, e.g. should
intersect([0, 0], [0])
return[0, 0]
or[0]
? the author's reference solution in JS, which is the original language, does this:This comment is hidden because it contains spoiler information about the solution
Solutions below (potentially more) should be disabled in Ruby
https://www.codewars.com/kata/reviews/5564d1d017229acdc800003b/groups/56216bc9c56f6efe88000061
https://www.codewars.com/kata/reviews/5564d1d017229acdc800003b/groups/55ca6ee3438a1bcced00006c
https://www.codewars.com/kata/reviews/5564d1d017229acdc800003b/groups/5a670e4e74df2abd26000ea7
https://www.codewars.com/kata/reviews/5564d1d017229acdc800003b/groups/619444406bf868000148106f
https://www.codewars.com/kata/reviews/5564d1d017229acdc800003b/groups/59e86516943fb2789b000d99
https://www.codewars.com/kata/reviews/5564d1d017229acdc800003b/groups/640d24c4830c6400017cd7e9
https://www.codewars.com/kata/reviews/5564d1d017229acdc800003b/groups/636976ae0e9afe00019c1eea
https://www.codewars.com/kata/reviews/5564d1d017229acdc800003b/groups/62752e29e3f82100014361fe
https://www.codewars.com/kata/reviews/5564d1d017229acdc800003b/groups/57d0591042e44e3f2800010b
https://www.codewars.com/kata/reviews/5564d1d017229acdc800003b/groups/58f47fde6fbd722342000131
Hello.
I use the Java language.
The tests pass, but when I try to send the code, writes: "For input string:"+"." Then follows Stacktrace, in which: "Java.lang.numberformatexception: for input string:"+". Next, Stacktrace ...".
My calculator returns 0.0 with a transferred line "+". I don’t understand what needs to be returned to go these tests.
I think that the exception should be returned to such a line: "+". Since this is not a mathematical expression. I think the decision is the correctness of the exclusion. But I can’t fully understand in which form to return the exception.
Who can direct to the right thought, please write?
This comment is hidden because it contains spoiler information about the solution
Java translation
CoffeeScript translation
I feel as though the description should be updated to note that multiple negations in a row is valid. I based a lot of my logic assuming this was invalid, as it is kind of unusual, to find only on the random tests that it happens.
If this is not intended, then the Haskell test cases generate invalid tests.
Regardless, I think it should be mentioned, at least.
Loading more items...