We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 330efe9 commit 6112c84Copy full SHA for 6112c84
examples/rayon-monte-carlo.rs
@@ -55,7 +55,7 @@ fn main() {
55
.into_par_iter()
56
.map(|i| {
57
let mut rng = ChaCha8Rng::seed_from_u64(SEED);
58
- // We chose ChaCha because it's fast, has suitable statical properties for simulation,
+ // We chose ChaCha because it's fast, has suitable statistical properties for simulation,
59
// and because it supports this set_stream() api, which lets us chose a different stream
60
// per work item. ChaCha supports 2^64 independent streams.
61
rng.set_stream(i);
@@ -69,7 +69,7 @@ fn main() {
69
}
70
count
71
})
72
- .reduce(|| 0usize, |a, b| a + b);
+ .sum::<usize>();
73
74
// prints something close to 3.14159...
75
println!(
0 commit comments