Created
November 17, 2012 12:47
-
-
Save soegaard/4095700 to your computer and use it in GitHub Desktop.
Implementation of lc53
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#lang racket/base | |
(define m (- (expt 2 32) 5)) | |
(define a (- (expt 2 32) 333333333)) | |
(define rand | |
(let ([xn 1]) | |
(λ () | |
(set! xn (modulo (* a xn) m)) | |
xn))) | |
(build-list 20 (λ(+) (rand))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment