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.
No random tests + translation outdated + author long time inactive => rejected
Excellent point! This solution doesn't, and fails tests where over/under flow is a concern.
Filtering entries that may cause issues with s-i then allows the original algorithm to work.
How does this deal with the potential overflow in
s-i
?Seems to panic.
needs random tests
This comment is hidden because it contains spoiler information about the solution
Amazing!
unapprovable due to changes in the description. Please fork the translation.
@g964 I will!
So I will approve it. Nevertheless you should ask CW to add some rand function:-)
@g964 See
This crate is on crates.io and can be used by adding rand to the dependencies in your project's Cargo.toml
line inUsage
. This is a crate supported by the officialrust-lang
team, but that it is not (yet) instd
.Sorry:-( but I am seeing that: https://doc.rust-lang.org/rand/rand/index.html. Can't you use it?
The problem is, Rust has no
rand
in std, so writing random tests is a bit hard in Rust...