Groups | Search | Server Info | Login | Register


Groups > comp.lang.lisp > #60784

Make a random-state from a non-random source

From Stefan Monnier <monnier@iro.umontreal.ca>
Newsgroups comp.lang.lisp
Subject Make a random-state from a non-random source
Date 2026-05-04 12:46 -0400
Organization A noiseless patient Spider
Message-ID <jwvmryfku8t.fsf-monnier+comp.lang.lisp@gnu.org> (permalink)

Show all headers | View raw


Reading the CLHS about `make-random-state` I can't see how to create
a "deterministic" random state.

I want it to be deterministic in the sense that if I re-run my program
(including after changing it a bit), I'll get the exact same sequence of
random numbers.
It's OK if the sequence is different when run on a different Lisp
implementation, OTOH.

I guess I could print a random state into a file and then read it back in,
but that depends on internals, so it's doubly messy.


=== Stefan

Back to comp.lang.lisp | Previous | NextNext in thread | Find similar


Thread

Make a random-state from a non-random source Stefan Monnier <monnier@iro.umontreal.ca> - 2026-05-04 12:46 -0400
  Re: Make a random-state from a non-random source Alan Bawden <alan@csail.mit.edu> - 2026-05-05 00:45 -0400
    Re: Make a random-state from a non-random source Stefan Monnier <monnier@iro.umontreal.ca> - 2026-05-05 16:03 -0400
  Re: Make a random-state from a non-random source tfb <no_email@invalid.invalid> - 2026-05-09 18:20 +0000
    Re: Make a random-state from a non-random source Stefan Monnier <monnier@iro.umontreal.ca> - 2026-05-11 11:23 -0400

csiph-web