Struct vrp_core::utils::DefaultRandom
source · pub struct DefaultRandom {}Expand description
A default random implementation.
Trait Implementations§
source§impl Default for DefaultRandom
impl Default for DefaultRandom
source§fn default() -> DefaultRandom
fn default() -> DefaultRandom
Returns the “default value” for a type. Read more
source§impl Random for DefaultRandom
impl Random for DefaultRandom
source§fn uniform_int(&self, min: i32, max: i32) -> i32
fn uniform_int(&self, min: i32, max: i32) -> i32
Produces integral random value, uniformly distributed on the closed interval [min, max]
source§fn uniform_real(&self, min: f64, max: f64) -> f64
fn uniform_real(&self, min: f64, max: f64) -> f64
Produces real random value, uniformly distributed on the closed interval [min, max)
source§fn is_head_not_tails(&self) -> bool
fn is_head_not_tails(&self) -> bool
Flips a coin and returns true if it is “heads”, false otherwise.