Re: Math.random() algorithm
- From: Randy Webb <HikksNotAtHome@xxxxxxx>
- Date: Thu, 06 Sep 2007 18:36:54 -0400
John G Harris said the following on 9/6/2007 3:46 PM:
On Wed, 5 Sep 2007 at 21:33:25, in comp.lang.javascript, Randy Webb
wrote:
Johannes Baagoe said the following on 9/5/2007 8:50 PM:Randy Webb :Gives me some fair insight into the thought process of the French.
Yet you still think a random number poses the best solution versus aIt does. Among other things, sequential numbers are nowhere
sequential number?
anonymous
enough. Forget them.
Be fair.
OK. I just find it odd that a society would think that random numbers, that have a probability of repeating - no matter how small that chance - is better than a system where the chance of repeating a number is impossible.
Random patient IDs make it unlikely that a small typo will
produce a valid ID, and hence the wrong patient.
That is true. And a simple solution exists for that. If you want a 16 digit patient ID, you create a database with those ID'es. You shuffle that database and then pick random entries from it. As you use an ID, you remove it from the database.
Either way, it doesn't really matter as the OP has already discounted that approach.
--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
.
- Follow-Ups:
- Re: Math.random() algorithm
- From: Johannes Baagoe
- Re: Math.random() algorithm
- References:
- Math.random() algorithm
- From: Johannes Baagoe
- Re: Math.random() algorithm
- From: Dr J R Stockton
- Re: Math.random() algorithm
- From: Johannes Baagoe
- Re: Math.random() algorithm
- From: Randy Webb
- Re: Math.random() algorithm
- From: Johannes Baagoe
- Re: Math.random() algorithm
- From: Randy Webb
- Re: Math.random() algorithm
- From: Johannes Baagoe
- Re: Math.random() algorithm
- From: Dr J R Stockton
- Re: Math.random() algorithm
- From: Randy Webb
- Re: Math.random() algorithm
- From: Johannes Baagoe
- Re: Math.random() algorithm
- From: Randy Webb
- Re: Math.random() algorithm
- From: John G Harris
- Math.random() algorithm
- Prev by Date: Re: problem with arrays, trying to dynamicly change the background of tabs
- Next by Date: Re: FAQ Topic - How do I disable the right mouse button?
- Previous by thread: Re: Math.random() algorithm
- Next by thread: Re: Math.random() algorithm
- Index(es):