seeded

Function seeded 

Source
pub fn seeded(seed: u64) -> Random<impl Rng + Clone> 
Expand description

Creates a new instance of the default PRNG with the given seed.

The seed does not need to look random, the PRNG constructor ensures it can handle degenerate seed values.

This function guarantees that the same seed always produces the same sequence of randomness.

§Examples

let mut rand = urandom::seeded(42);
let value: i32 = rand.next();
assert_eq!(value, 368317477);