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.
Approved
todo!()
to the solution setup so it compiles as-is.str_size
andlen
). The point of distributions is to create them once and sample many times. So you'd move them out ofgen_str
function. Frankly, there's no point in having that function, just inline it into thefor
loop (but leave the distributions outside).String
, then youcollect
, then youjoin
. Why the final join? Simply map tochar
and collect toString
(this saves intermediate allocations).30
, instead of1
Rust translation finished.
AFAIK, there is no readily available BigInt in Rust.Added anti-cheat.
Prolog Translation ready for review.
I tried to replicate test cases 1:1 with the Rust version that I had access to.
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.
This was by far the most interesting kata I have done on this site.
Thanks
I mean, its semi-ambiguously mentioned:
The exception is if there is no other rank left to progress towards (Once you reach rank 8 there is no more progression).
I took that as rank 8 does not have progress, but that should definitely be clearer.
I know this is old comment, but for anyone else wondering: https://docs.codewars.com/gamification/ranks/
Each rank is defined by having a certain score. Each kata is worth a constant score.
e.g. 8kyu always award 2
However, reaching 4kyu takes 643 score. So its impractical to level up on easier problems.
Its saying that during an assertion, the tests expected an exception from your code but did not recieve one.
In the prompt it tells you that any rank that isn't -8 through -1 or 1 through 8 should throw an exception
Modified.
(Rust)
The description refers to n as the index of the block and m as the volume.
However, the function provided gives n as the parameter, when it should be m.