Discover Packages
github.com/dgryski/go-pcgr
package
module
Version:
v0.0.0-...-4b34ab9
Opens a new window with list of versions in this module.
Published: Nov 1, 2021
License: MIT
Opens a new window with license information.
Imports: 0
Opens a new window with list of imports.
Imported by: 20 modules, 24 packages
The first number is the count of modules that contain a package that imports this one.
The module count is a better indicator of popularity than the package count.
A module with 100 importing packages is counted only once instead of 100 times,
reflecting the fact that the choice to use the package was likely made only once,
not 100 times.
A '?' means that the value hasn't been computed yet.
Opens a new window with list of known importers.
README
README
¶
godoc: https://godoc.org/github.com/dgryski/go-pcgr
Expand ▾
Collapse ▴
Documentation
¶
Package pcgr implements a small PCG random number generator
http://www.pcg-random.org/
Rand is a PCG random number generator. It implements the rand.Source interface.
New returns an pcgr stream
Advance skips forward 'delta' steps in the stream. Delta can be negative in which case the stream in rewound.
func (*Rand) Bound ¶
Bound returns a uniform integer 0..bound-1
func (*Rand) Int63 ¶
Int63 returns a random 63-bit integer
func (*Rand) Next ¶
Next returns a random uint32
func (*Rand) Seed ¶
Seed states the internal state of the rng
func (r *Rand ) SeedWithState(initstate, initseq int64 )
SeedWithState sets the internal state and sequence number of the rng
Source Files
¶
Click to show internal directories.
Click to hide internal directories.