Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nasa9084/go-mersenne-twister
An implementation of Mersenne Twister in Go
https://github.com/nasa9084/go-mersenne-twister
Last synced: 11 days ago
JSON representation
An implementation of Mersenne Twister in Go
- Host: GitHub
- URL: https://github.com/nasa9084/go-mersenne-twister
- Owner: nasa9084
- License: other
- Created: 2017-01-27T14:59:56.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2019-01-04T14:16:29.000Z (almost 6 years ago)
- Last Synced: 2024-10-05T00:40:53.026Z (about 1 month ago)
- Language: Go
- Homepage:
- Size: 25.4 KB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# go-mersenne-twister
[![MIT License](http://img.shields.io/badge/license-MIT-blue.svg?style=flat)](LICENSE)
[![Build Status](https://travis-ci.org/nasa9084/go-mersenne-twister.svg?branch=master)](https://travis-ci.org/nasa9084/go-mersenne-twister)
[![GoDoc](https://godoc.org/github.com/nasa9084/go-mersenne-twister?status.svg)](https://godoc.org/github.com/nasa9084/go-mersenne-twister)Implementation of Mersenne Twister in Go
## Usage
``` go
package mainimport (
"fmt"
"github.com/nasa9084/go-mersenne-twister"
)func main() {
mt.InitGenrand(0) // '0' is a seed. choose freely.
n := mt.GenrandInt32() // generate int 32 random value.
fmt.Printf("%d", n)
}
```