Fuzion Logo
flang.dev — The Fuzion Language Portal
JavaScript seems to be disabled. Functionality is limited.

random

🌌random

random -- effect that provides random numbers

get the current random number in the range 0..max-1

for a random instance installed in the current environment, update the
environment to the next random value. The the contents of the current
instance are left unchanged, 'random.env' will provide the new instance.

return next random number as a bool

return next random number of type f32 in the range [0..1),
result will never be equal to f32 1

return next random number of type f64 in the range [0..1),
result will never be equal to f64 1

return next random number of type i32 in the range 0..max-1

return next random number of type i64 in the range 0..max-1

return next random number of type u32 in the range 0..max-1

return next random number of type u64 in the range 0..max-1