Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need formula for Random ##'s within range AND Relative to each other 3

Status
Not open for further replies.

kwbMitel

Technical User
Oct 11, 2005
11,504
CA
I'm creating a spreadsheet to generate Lottery Ticket numbers. Why? To settle a bet.

Randbetween(1,49) is great for 1 number but I need 6 NON-Matching numbers withing the range.

I've gotten around this for now by generating 12 numbers and using if then statements to find the first 6 unique numbers but I don't think this method will satisfy my sceptics.

Is there a simple formula to generate 6 distinct, non-matching numbers within a range? (1 - 49)

*******************************************************
Occam's Razor - All things being equal, the simplest solution is the right one.
 
strongm: I would expect a computer program to be more random than the actual lottery....
Because of the inherant imperfections in manufacturing seemingly identical balls (laughable) painting/stenciling numbers on them with identical weighting and balance (snicker) and dumping them in a container in a means that is completely random (give me a break) and using some mechanical means to select balls that is itself random (out of euphemisms).

The lottery ball selection process has so many imperfections in fact that said imperfections could actually contibute to the randomness. (but I think not)

I still think a computer is more random, sorry.

*******************************************************
Occam's Razor - All things being equal, the simplest solution is the right one.
 
Strongm: P.S. do you really think I can understand the document that you linked to?

If so, thank you for the compliment.

Can we agree that both methods have their inherent faults and leave it at that?

*******************************************************
Occam's Razor - All things being equal, the simplest solution is the right one.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top