Sub topic 6
Variance and Streaks: Why Short Runs Feel Unfair
Assume you know basic percentages, dice, cards, and simple Python. This chapter focuses on how random results vary around an average. It also explains why players may call a fair system “rigged” after a short unlucky run.
Expected value is not a promise
Expected value is the long-run average result of a random process. A fair six-sided die has an expected value of 3.5 because its face values add to 21, and 21 divided by 6 is 3.5.
A single roll does not need to be close to 3.5. It must produce an integer from 1 to 6. Even after many rolls, the average can remain above or below 3.5 for a while.
Variance measures how widely results spread around their average. High variance creates larger swings and more extreme outcomes. Low variance keeps results closer to the expected value.
| System | Expected result | Variance pattern | Player experience |
|---|---|---|---|
| One six-sided die | 3.5 | High for one roll | Dramatic swings |
| Sum of Custom dice | 7 | Lower than one die | More predictable totals |
| Fixed damage value | 7 | None | Reliable but less surprising |
The word “custom” in the table means a pair of dice, not a special die. With two dice, very low and very high totals require more specific combinations. Middle totals have more combinations, so results cluster near the average.
Why streaks occur
Independent trials do not remember previous results. If a spell has a 30% chance to hit, its chance remains 30% after five misses unless the game changes the rule.
A miss streak can still be likely. Five misses in a row have probability:
0.70 × 0.70 × 0.70 × 0.70 × 0.70 = 0.16807
That is about 16.8%. In a game with many players and many attempts, some players will experience this streak often. Players usually remember the streak more clearly than the ordinary hits around it.
import random
def longest_streak(results):
if not results:
return 0
best = run = 1
for previous, current in zip(results, results[1:]):
run = run + 1 if current == previous else 1
best = max(best, run)
return best
rng = random.Random(7)
flips = [rng.choice(["heads", "tails"]) for _ in range(100)]
print("Longest streak:", longest_streak(flips))This code models fair coin flips. A long run does not prove that the random generator failed. It may be a normal result of variance.
Design responses to perceived unfairness
First decide whether the streak creates useful tension or needless frustration. High variance can make a critical hit exciting, but it can also make a player’s careful plan irrelevant.
Use mitigation when the player needs reliable control:
- Let players spend a resource to reroll.
- Give partial progress after a failure.
- Reduce the chance of repeated extreme results.
- Use a guaranteed reward after a maximum number of misses.
- Allow strategic choices that improve the odds.
These tools change the distribution. Document that change clearly, because a system with hidden protection may be difficult to test and explain.
Exercise
A reward has a 20% chance to appear on each independent attempt. What is the probability of missing it five times in a row, and should the fifth miss automatically increase the sixth attempt's chance?
Show answer
The probability is 0.8^5, or 32.768%. No. The sixth attempt remains 20% unless the design adds a pity rule or another form of bad-luck protection.