IdrisDoc: Control.ST.Random

# Control.ST.Random

rndSelect' : (rnd : Var) -> Vect (S k) a -> ST m a [rnd ::: Random]

  Select a random element from a vector

rndSelect : (rnd : Var) -> (xs : List a) -> {auto ok : NonEmpty xs} -> ST m a [rnd ::: Random]

  Select a random element from a non-empty list

rndInt : (rnd : Var) -> Integer -> Integer -> ST m Integer [rnd ::: Random]

  Generates a random Integer in a given range

rndFin : (rnd : Var) -> (k : Nat) -> ST m (Fin (S k)) [rnd ::: Random]

  Generate a random number in `Fin (S k)`

  Note that rndFin k takes values 0, 1, ..., k.

getRandom : (rnd : Var) -> ST m Integer [rnd ::: Random]
Random : Type