in reply to Re: Re: check my logic & a random number issue
in thread check my logic & a random number issue
Of course, if you're not using a truely random or very, very convincing pseudo-random generator you probably won't quite get these probabilities.Value Probability Combinations 1 0 2 1/36 1:1 3 2/36 1:2, 2:1 4 3/36 1:3, 2:2, 3,1 5 4/36 1:4, 2:3, 3:2, 4:1 6 5/36 1:5, 2:4, 3:3, 4:2, 5:1 7 6/36 1:6, 2:5, 3:4, 4:3, 5:2, 6:1 8 5/36 2:6, 3:5, 4:4, 5:3, 6:2 9 4/36 3:6, 4:5, 5:4, 6:3 10 3/36 4:6, 5:5, 6:4 11 2/36 5:6, 6:5 12 1/36 6:6
Considering that 7 is a bad number to get in Craps, it'd be nicer to use just a 12 sided dice, but then the Casinos would have to rig the game another way to get their money. ;)
It's good to know that for this kind of example rand() is as good as Math::Random.
jarich
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: Re: check my logic & a random number issue
by rmckillen (Novice) on Oct 11, 2002 at 17:21 UTC |