Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

Random/seed

 [1/5] from: robert::lancaster::opennw::com at: 18-Apr-2001 9:09


Hello All... random/seed 1 while [ 1 ] [ print random 100 ] ; on a Win 98 box.... Always produces an identical list of random numbers everytime it's run. Can this be relied on to produce the same identical list of random numbers, each time it is run on varying platforms? I have to ask because I only have access to one type of platform. Thanks.. p.s Glad to see I can open a UDP listen port under 2.5 now....I had great trouble with it before... Don't ask me why.. I just did! Rob Lancaster Email: [Rob--Lancaster--opennw--com]

 [2/5] from: ryanc:iesco-dms at: 17-Apr-2001 15:47


I get this set of numbers on my Windows and Linux boxes using PII's. I expect it might be different on non Intel machines.
>> random/seed 1 loop 20 [ print random 100 ]
95 52 80 96 67 32 53 12 4 15 71 32 67 30 57 86 35 20 66 41 Robert Lancaster wrote:
> Hello All... > random/seed 1 while [ 1 ] [ print random 100 ] ; on a Win
<<quoted lines omitted: 12>>
> [rebol-request--rebol--com] with "unsubscribe" in the > subject, without the quotes.
-- Ryan Cole Programmer Analyst www.iesco-dms.com 707-468-5400 I am enough of an artist to draw freely upon my imagination. Imagination is more important than knowledge. Knowledge is limited. Imagination encircles the world. -Einstein

 [3/5] from: norsepower:uswest at: 17-Apr-2001 19:44


I get the same sequence on the BeOS -Ryan REBOL/View 1.0.0.5.2 6-Apr-2001 Copyright 2000-2001 REBOL Technologies. All rights reserved. REBOL is a trademark of REBOL Technologies. WWW.REBOL.COM Internet Protocols 1.50.0 29-Mar-2001/23:18:14 REBOL Network Auto-Configure 1.5.0 2-Apr-2001/23:24:48 REBOL Installer 1.32.0 3-Apr-2001/20:55:54 View and VID 1.154.0 1-Apr-2001/0:25:53 REBOL Preferences 1.44.0 6-Apr-2001/23:11:57 Type DEMO for REBOL demo or SET-USER for settings.
>> random/seed 1 loop 20 [ print random 100 ]
95 52 80 96 67 32 53 12 4 15 71 32 67 30 57 86 35 20 66 41

 [4/5] from: robert:lancaster:opennw at: 18-Apr-2001 15:13


Thanks a lot for the help every one. I was looking at using it to produce a numbering system for a protocol over UDP. Trying to get a method for working out which packets had gone missing by their internal data, numbering and/or length. Realised there's a few holes in my logic. So having a rethink... Might have to write my own Pseudo Random Number Generator, so I can get random non-repeating numbers.

 [5/5] from: chris:starforge at: 18-Apr-2001 9:14


#17-Apr-01# Message from *Robert Lancaster*: Hi Robert,
> Can this be relied on to produce the same identical list of random > numbers, each time it is run on varying platforms?
If the random number generator avoids direct bit fiddling (or it takes care of endian issues) and the same implementation is used on every platform then you will always get the same number sequence for a given seed regardless of platform. Chris -- New sig in the works Explorer 2260, Designer and Coder http://www.starforge.co.uk -- ODD SIGNS FROM ENGLAND 23. ON A REPAIR SHOP DOOR: We can repair anything (Please knock hard on the door - the bell doesn't work)

Notes
  • Quoted lines have been omitted from some messages.
    View the message alone to see the lines that have been omitted