If you’ve ever watched an Ocarina of Time 100% speedrun, or played the game yourself, you’ll probably know about Dampe. As a gravedigger in Kakariko graveyard, he’ll offer to dig up graves for you when you go to him as child Link to get a random treasure. If you’re mildly lucky, you’ll get enough rupees to try again. If you’re really lucky, you’ll get the heart piece.
The latter is obviously part of the 100% definition of the game, so hundo speedruns sooner or later have to face dampe and gamble on the 10% chance of him digging up the heartpiece.

As one of the few major rng-depdenent1 events in the run he’s kind of notorius, especially when he kills multiple runs in a row by needing more than 10 attempts to finally get the heart piece.
The math itself is pretty straight forward: In a speedrun, runners use a method to reset Dampe to a specific plot, allowing them to dig on the same grave spot over and over again, theoretically ad infinitum. While this method is not as “safe” as the intended method, which is capped at 15 tries maximum, it’s significantly faster unless you get “bad Dampe rng”. Each time Dampe digs, there’s a 10% chance to get the heartpiece, which means in mathy terms we can define $p = 0.1$ and $k =$ number of tries until success, giving us:

$P(k = 1) = p = 0.1$

Second try Dampe would be the probability of “failing” the first attempt and then succeed afterwards, or:

$P(k = 2) = (1-p) \times p = 0.9 \times 0.1 = 0.09$

And in general terms:

$P(k) = (1-p)^{k-1} \times p$

Which, conveniently, is known as the geometric distribution. In R, we can calculate individual probabilities (densities) using dgeom(x, prob = .1) to get the probability for “failing x times before success”, meaning we need to use k = x - 1 to get the number of attempts it took to get the heartpiece, include the last dig.

So, with a lot of talk about odds and chances and whatnot every time Dampe is misbehaving again, I thought I’d take the opportunity to make a little lookup table to see just how unlikely your latest 61st try Dampe really was.

Here’s what’s included:

• Attempt: How often you had to let Dampe dig until the heart piece, $k$
• Probability, %: The probability for $k$, as a singular outcome
• Probability (Total), % (Total): Probability of $1$ through $k$ tries, i.e. the probability for getting $k$ or lower tries
• Odds (Singular): $\frac{1}{\text{Probability}}$, the probability for that outcome in human readable terms
Attempt Probability % Probability (Total) % (Total) Odds (Singular)
1 0.1000000 10.00% 0.1000000 10.0% 1 in 10
2 0.0900000 9.00% 0.1900000 19.0% 1 in 12
3 0.0810000 8.10% 0.2710000 27.1% 1 in 13
4 0.0729000 7.29% 0.3439000 34.4% 1 in 14
5 0.0656100 6.56% 0.4095100 41.0% 1 in 16
6 0.0590490 5.90% 0.4685590 46.9% 1 in 17
7 0.0531441 5.31% 0.5217031 52.2% 1 in 19
8 0.0478297 4.78% 0.5695328 57.0% 1 in 21
9 0.0430467 4.30% 0.6125795 61.3% 1 in 24
10 0.0387420 3.87% 0.6513216 65.1% 1 in 26
11 0.0348678 3.49% 0.6861894 68.6% 1 in 29
12 0.0313811 3.14% 0.7175705 71.8% 1 in 32
13 0.0282430 2.82% 0.7458134 74.6% 1 in 36
14 0.0254187 2.54% 0.7712321 77.1% 1 in 40
15 0.0228768 2.29% 0.7941089 79.4% 1 in 44
16 0.0205891 2.06% 0.8146980 81.5% 1 in 49
17 0.0185302 1.85% 0.8332282 83.3% 1 in 54
18 0.0166772 1.67% 0.8499054 85.0% 1 in 60
19 0.0150095 1.50% 0.8649148 86.5% 1 in 67
20 0.0135085 1.35% 0.8784233 87.8% 1 in 75
21 0.0121577 1.22% 0.8905810 89.1% 1 in 83
22 0.0109419 1.09% 0.9015229 90.2% 1 in 92
23 0.0098477 0.98% 0.9113706 91.1% 1 in 102
24 0.0088629 0.89% 0.9202336 92.0% 1 in 113
25 0.0079766 0.80% 0.9282102 92.8% 1 in 126
26 0.0071790 0.72% 0.9353892 93.5% 1 in 140
27 0.0064611 0.65% 0.9418503 94.2% 1 in 155
28 0.0058150 0.58% 0.9476652 94.8% 1 in 172
29 0.0052335 0.52% 0.9528987 95.3% 1 in 192
30 0.0047101 0.47% 0.9576088 95.8% 1 in 213
31 0.0042391 0.42% 0.9618480 96.2% 1 in 236
32 0.0038152 0.38% 0.9656632 96.6% 1 in 263
33 0.0034337 0.34% 0.9690968 96.9% 1 in 292
34 0.0030903 0.31% 0.9721872 97.2% 1 in 324
35 0.0027813 0.28% 0.9749684 97.5% 1 in 360
36 0.0025032 0.25% 0.9774716 97.7% 1 in 400
37 0.0022528 0.23% 0.9797244 98.0% 1 in 444
38 0.0020276 0.20% 0.9817520 98.2% 1 in 494
39 0.0018248 0.18% 0.9835768 98.4% 1 in 549
40 0.0016423 0.16% 0.9852191 98.5% 1 in 609
41 0.0014781 0.15% 0.9866972 98.7% 1 in 677
42 0.0013303 0.13% 0.9880275 98.8% 1 in 752
43 0.0011973 0.12% 0.9892247 98.9% 1 in 836
44 0.0010775 0.11% 0.9903023 99.0% 1 in 929
45 0.0009698 0.10% 0.9912720 99.1% 1 in 1,032
46 0.0008728 0.09% 0.9921448 99.2% 1 in 1,146
47 0.0007855 0.08% 0.9929303 99.3% 1 in 1,274
48 0.0007070 0.07% 0.9936373 99.4% 1 in 1,415
49 0.0006363 0.06% 0.9942736 99.4% 1 in 1,572
50 0.0005726 0.06% 0.9948462 99.5% 1 in 1,747
51 0.0005154 0.05% 0.9953616 99.5% 1 in 1,941
52 0.0004638 0.05% 0.9958254 99.6% 1 in 2,156
53 0.0004175 0.04% 0.9962429 99.6% 1 in 2,396
54 0.0003757 0.04% 0.9966186 99.7% 1 in 2,662
55 0.0003381 0.03% 0.9969567 99.7% 1 in 2,958
56 0.0003043 0.03% 0.9972611 99.7% 1 in 3,286
57 0.0002739 0.03% 0.9975350 99.8% 1 in 3,652
58 0.0002465 0.02% 0.9977815 99.8% 1 in 4,057
59 0.0002219 0.02% 0.9980033 99.8% 1 in 4,508
60 0.0001997 0.02% 0.9982030 99.8% 1 in 5,009
61 0.0001797 0.02% 0.9983827 99.8% 1 in 5,565
62 0.0001617 0.02% 0.9985444 99.9% 1 in 6,184
63 0.0001456 0.01% 0.9986900 99.9% 1 in 6,871
64 0.0001310 0.01% 0.9988210 99.9% 1 in 7,634
65 0.0001179 0.01% 0.9989389 99.9% 1 in 8,482
66 0.0001061 0.01% 0.9990450 99.9% 1 in 9,425
67 0.0000955 0.01% 0.9991405 99.9% 1 in 10,472
68 0.0000860 0.01% 0.9992264 99.9% 1 in 11,635
69 0.0000774 0.01% 0.9993038 99.9% 1 in 12,928
70 0.0000696 0.01% 0.9993734 99.9% 1 in 14,364
71 0.0000627 0.01% 0.9994361 99.9% 1 in 15,960
72 0.0000564 0.01% 0.9994925 99.9% 1 in 17,733
73 0.0000508 0.01% 0.9995432 100.0% 1 in 19,704
74 0.0000457 0.00% 0.9995889 100.0% 1 in 21,893
75 0.0000411 0.00% 0.9996300 100.0% 1 in 24,326
76 0.0000370 0.00% 0.9996670 100.0% 1 in 27,028
77 0.0000333 0.00% 0.9997003 100.0% 1 in 30,031
78 0.0000300 0.00% 0.9997303 100.0% 1 in 33,368
79 0.0000270 0.00% 0.9997573 100.0% 1 in 37,076
80 0.0000243 0.00% 0.9997815 100.0% 1 in 41,195
81 0.0000218 0.00% 0.9998034 100.0% 1 in 45,772
82 0.0000197 0.00% 0.9998230 100.0% 1 in 50,858
83 0.0000177 0.00% 0.9998407 100.0% 1 in 56,509
84 0.0000159 0.00% 0.9998567 100.0% 1 in 62,788
85 0.0000143 0.00% 0.9998710 100.0% 1 in 69,764
86 0.0000129 0.00% 0.9998839 100.0% 1 in 77,516
87 0.0000116 0.00% 0.9998955 100.0% 1 in 86,128
88 0.0000104 0.00% 0.9999060 100.0% 1 in 95,698
89 0.0000094 0.00% 0.9999154 100.0% 1 in 106,331
90 0.0000085 0.00% 0.9999238 100.0% 1 in 118,146
91 0.0000076 0.00% 0.9999314 100.0% 1 in 131,273
92 0.0000069 0.00% 0.9999383 100.0% 1 in 145,859
93 0.0000062 0.00% 0.9999445 100.0% 1 in 162,065
94 0.0000056 0.00% 0.9999500 100.0% 1 in 180,073
95 0.0000050 0.00% 0.9999550 100.0% 1 in 200,081
96 0.0000045 0.00% 0.9999595 100.0% 1 in 222,312
97 0.0000040 0.00% 0.9999636 100.0% 1 in 247,013
98 0.0000036 0.00% 0.9999672 100.0% 1 in 274,459
99 0.0000033 0.00% 0.9999705 100.0% 1 in 304,954
100 0.0000030 0.00% 0.9999734 100.0% 1 in 338,838
101 0.0000027 0.00% 0.9999761 100.0% 1 in 376,487
102 0.0000024 0.00% 0.9999785 100.0% 1 in 418,318
103 0.0000022 0.00% 0.9999806 100.0% 1 in 464,798
104 0.0000019 0.00% 0.9999826 100.0% 1 in 516,442
105 0.0000017 0.00% 0.9999843 100.0% 1 in 573,825

1. Random number generator, in speedrunning terms it’s become synonymous with ‘random event’ and ‘specific outpcome of an event determined by [pseudo] random number generation’