In the game “Drop Dead,” you roll
a number of six-sided dice. If a roll
does not include any 2s or 5s, you
add the sum of the dice to your
score and roll all of the dice again.
If your roll does include 2s or 5s,
you receive no points for that roll,
the dice with 2s or 5s are discarded,
and the remaining dice are rolled again. You repeat this procedure until all dice have been discarded.
If you start with five dice, what is your
expected score by the time you have
discarded all of your dice?
Not sure where my prior error was, but here is the program output not from a simulation but from a formula in which Sn relies on all the previous values S(n-1) etc.
(plus or minus rounding area)
1 6.999999999999999
2 11.2
3 13.705263157894734
4 15.190283400809712
5 16.06466220235239
6 16.57582746512653
7 16.87239246868453
8 17.04307100328293
9 17.140469183548312
10 17.19555864689272
fwiw, The score appears to approach an asymptote
198 17.264124251524965
199 17.264124252025212
200 17.264124252428164
code:
------------
s_of_n = [0]
for n in range(1,11):
multiplier = (3**n) / (3**n - 2**n)
ans = (2/3)**n * 3.5 * n
for k in range(1,n):
ans += (combin(n,k)
* (1/3)**k
* (2/3)**(n-k)
* s_of_n[n-k])
s_of_n.append(ans*multiplier)
for i,v in enumerate(s_of_n):
if i == 0:
continue
print(i,v)
|
Posted by Larry
on 2024-12-02 15:13:23 |