Sure, you could just do `random() % amount` to get a random array index. But then you start to read and after hours you end up with `let range = Uniform::new(0, amount); let mut rng = thread_rng(); range.sample(&mut rng);` because it will make such a big difference! #rust
Programmer, OpenSource enthusiast and hacker based in Berlin, Germany.
The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!