11 Sep
2007
11 Sep
'07
10:53
Hi! I'm using the random-integer function, but it would seem that it always give the same set of results after each execution... I then guessed I had to set the random seed, somehow but I couldn't figure out the way to do it... I tried something like: (set! default-random-source (make-random-source)) (random-source-randomize! default-random-source) (pp (random-integer 10)) (pp (random-integer 10)) (pp (random-integer 10)) And tried to run it multiple times and I still get the same answer each time I run this simple program... :( What should be done to make this random? Shouldn't be that the default-random-source produce different random integers at each program launch?? Thanks! David