Function polkadot_node_subsystem_util::gen_ratio_rng
source · pub fn gen_ratio_rng<R: Rng>(a: usize, b: usize, rng: &mut R) -> bool
Expand description
Returns a bool
with a probability of a / b
of being true.
pub fn gen_ratio_rng<R: Rng>(a: usize, b: usize, rng: &mut R) -> bool
Returns a bool
with a probability of a / b
of being true.