Eight men, including Colonel Mustard, sit at a round table, for a modified game of Russian roulette. They are using a six chamber revolver which has been loaded with 5 bullets.
The game begins by one of the men reaching into a hat, and randomly drawing the name of the first player.
If the first player survives his turn, the gun is handed to his adjacent clockwise neighbor, and his name is immediately returned to the hat.
If the first player loses, his name is thrown away, and the men pull from the hat, and choose the name of the next player.
The game is continued in such a way until either all five bullets have fired, OR a player survives his turn, but no longer has an adjacent clockwise neighbor to pass the gun to.
What is the probability that the Colonel will survive the game?
(Note that the chamber is spun every time a player takes his turn).
DEFDBL A-Z
RANDOMIZE TIMER
FOR trial = 1 TO 1000000
FOR i = 1 TO 8: player(i) = 1: NEXT
bullets = 5
ptr = 1
DO
r = INT(RND(1) * 6 + 1)
IF r <= bullets THEN
player(ptr) = 0
bullets = bullets - 1
DO
r = INT(RND(1) * 8 + 1)
LOOP UNTIL player(r) = 1
ptr = r
ELSE
ptr = ptr + 1
IF ptr > 8 THEN ptr = 1
END IF
IF player(ptr) = 0 OR bullets = 0 THEN EXIT DO
LOOP
FOR i = 1 TO 8
IF player(i) = 0 THEN
pDead(i) = pDead(i) + 1
dead = dead + 1
END IF
NEXT
IF bullets = 0 THEN exhaust = exhaust + 1
FOR i = 1 TO 8
PRINT USING " #.####"; pDead(i) / trial;
NEXT: PRINT
PRINT USING " #.####"; dead / trial; exhaust / trial;
PRINT trial, dead / (8 * trial)
NEXT
produces as its last set of data:
0.8854 0.3238 0.2934 0.3086 0.3157 0.3182 0.3167 0.3141
3.0759 0.0863 1000000 .384482375
indicating that after one million trials, the average trial resulted in 3.0759 deaths, giving any one of its players (since they all have equal likelihood of going first, and at any remaining stage of having his name pulled) a probability equal to that number divided by 8 (the number of players). That probability is thus about 38.45%, and his probability of survival is about 61.55%.
The other numbers shown indicate that only about 8.63% of the times this game would be played are all the bullets used.
The series at the top represent the probabilities just after the first player has been selected. Whoever that player is, at that point has an 88.54% probability of losing his life, which of course is larger than his immediate danger of 83.33%, as he may also die in subsequent rounds. The person immediately clockwise from the first-selected person has a 32.38% of losing, part of which is the (1/6)*(5/6) = 5/36 of an initial miss and then hit. Subsequent numbers show the probability for successive physical positions clockwise from the unlucky initially-selected person. The probabilities are accurate enough that the orders of their sizes seem consistent from run to run, and must be affected by being in the "shadow" of empty seats (dead men's positions).
|
Posted by Charlie
on 2010-06-08 14:14:29 |