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.
Randomized testing in Haskell (and maybe other languages) can result in the following:
The description lacks enough detail to determine sorting behavior between letters and characters whose ASCII value falls between the upper and lowercase letter ranges:
[\]^_`
This comment is hidden because it contains spoiler information about the solution
Unless absolutely necessary because it no longer passes, I don't like changing the example solution, because it will be published under the original author's name, not yours. In this case, I don't think it's necessary.
forAll arbitrary
is justproperty
, which also gives shrinking.Why do you change
Int
toInteger
, when you then only test from-100
to100
in random tests?Random tests always start with generating
0
, because testsize
starts from0
. So the separate edge case is unnecessary. ( You may then want to document that the first random tests will always besquareDigit 0
. )I've forked the Haskell translation here to add random cases and clean a few things up.
indeed
This comment is hidden because it contains spoiler information about the solution
I never ran into any problem. I had no idea there was any. I also have no idea why there was a difference between Submit and Sample Tests anyway.
ETA: it's probably a refactoring fossil
Approved. That made me nearly go nuts. Thank you.
This comment is hidden because it contains spoiler information about the solution
Sample tests in Haskell fail due to a faulty function signature. I've put in a translation here that fixes it.
(?)
in sample tests.My previous solution didn't take advantage of the fact that the commands would keep the robot in the space of non-negative coordinates.
Integer
.Loading more items...