W3cubDocs

/Nim

Module mersenne

Types

MersenneTwister = object
  mt: array[0 .. 623, uint32]
  index: int

Procs

proc newMersenneTwister(seed: uint32): MersenneTwister {...}{.raises: [], tags: [].}
A type specialized version of .. for convenience so that mixing integer types work better.
proc getNum(m: var MersenneTwister): uint32 {...}{.raises: [], tags: [].}
Returns the next pseudo random number ranging from 0 to high(uint32)

© 2006–2018 Andreas Rumpf
Licensed under the MIT License.
https://nim-lang.org/docs/mersenne.html