huangzworks / SICP-answers

我的 SICP 解题集

Home Page:http://sicp.readthedocs.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

修复练习 3.6 的答案

huangzworks opened this issue · comments

http://sicp.readthedocs.org/en/latest/chp3/6.html#comment-770974238

需要一种根据相同 state 生成连续随机数的 random 函数,比如:

(rand-init 10086)
(random) => r1
(random) => r2
(random) => r3

(rand-init 10086)
(random) => r21
(random) => r22
(random) => r23

其中 r1 == r21r2 == r22r3 == 23