How Random is Random?
From: Phil Schaechter (Phil.Schaechter_at_datadomain.com)
Date: 03/30/04
- Next message: Philip Villamin: "gtk problem"
- Previous message: Daniel Stellwagen: "Re: AW: Regexp match question !"
- Next in thread: Bram Mertens: "Re: How Random is Random?"
- Reply: Bram Mertens: "Re: How Random is Random?"
- Reply: John W. Krahn: "Re: How Random is Random?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
To: beginners@perl.org Date: Tue, 30 Mar 2004 10:48:01 -0800
The documentation on "keys" and "each" says something like the following:
--- Returns a list consisting of all the keys of the named hash. (In scalar context, returns the number of keys.) The keys are returned in an apparently random order. --- I have a database (>50,000 items) that I would like to select things from randomly. I would like to "eventually" select all of the items from the database, but there are no time constraints. The database is constantly being changed. If I use keys to select 100 items to process, then come back at a later date and pick another 100, and so on, will I eventually hit "most" of the items? My own experiments show this to be more or less true - but I'd like to know if anyone can explain to me how random is random. -Phil
- Next message: Philip Villamin: "gtk problem"
- Previous message: Daniel Stellwagen: "Re: AW: Regexp match question !"
- Next in thread: Bram Mertens: "Re: How Random is Random?"
- Reply: Bram Mertens: "Re: How Random is Random?"
- Reply: John W. Krahn: "Re: How Random is Random?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|