# Drawing as many cards as possible, what are the odds of drawing a beneficial order of cards from the Deck of Many Things?

I just "won" at the Deck of Many Things. I'm legit curious. Beyond that actually. What are the odds of what just happened, happening?

(Also, the DM reading my character flaws and letting me find this is one of the lowest moves I've ever seen pulled.)

Context: I just leveled up. I am 0 XP over level 11 (i.e. I have exactly 85,000 XP total). I am True Neutral. I have no money or non-magical items on my person. I can only stop drawing single cards after drawing Talons. Drawing Talons is a Campaign End card unless I've drawn The Moon or The Fates.

Drawing as many cards as possible, what are the odds of drawing a beneficial order of cards from the Deck of Many Things (with a Good End)?

Card class (Good, Neutral, Bad) can change depending on order drawn.

No cards that end in a Bad card class by stopping. I must draw until I hit a stopping condition. Cards are not replaced after being drawn per a homebrew rule, which gives progressively worse odds of drawing a bad card.

To help with the math/reasoning here's a list of cards and card class:

• The Fates - Good (Negate any single card draw)
• Vizier - Good
• Comet - Good
• Gem - Good
• Jester - Good
• Key - Good
• Knight - Good
• Moon - Good
• Star - Good
• Sun - Good
• Balance - Neutral
• Throne - Neutral
• Ruin - Neutral
• Fool - Neutral (Bad if drawn after Jester or Sun, draw again)
• Flames - Neutral (Technically Bad but fine for our case)
• Rogue - Bad (Unless Moon drawn before stopping)
• Talons - Bad (Stopping Condition, must have Moon or Fates to become Good End)

Additional Note: Moon gives 3 wishes, which you can use like Fates for our purposes; you cannot wish for more wishes, and you cannot wish it back in the deck. To keep it more simple, we're looking for max benefit with max cards, so using more than a single Wish or Fate to avert Talons (our required stopping condition) is bad.

• Comments are not for extended discussion; this conversation has been moved to chat.
– V2Blast
Jul 4, 2019 at 21:49

Because there's no card replacement, this actually makes the math a little friendlier than it would otherwise be.

The runs that matter require three conditions to be true:

• They stopped on a "Talons" card
• Before they stopped, they landed on at least one of either a "Moons" or "Fates" card
• They did not draw any "Bad" cards at any point in the run

The question is ambiguous as to whether a good run must only contain "Good" cards, or may also contain "Neutral" cards, so I've split the data into two tables: runs that fulfill these requirements that only contain "Good" cards (and "Talons") and runs that contain "Good" or "Neutral" cards (and "Talons"):

# of Good Cards Odds (as %)
2 1/231 0.433
3 17/4620 0.368
4 16/7315 0.219
5 2/1881 0.106
6 14/31977 0.044
7 13/85272 0.015
8 7/159885 0.004
9 1/101745 0.001
10 1/646646 0.0002
11 1/7759752 0.00001
# of Good/Neutral Cards Odds (as %)
2 1/231 0.433
3 1/165 0.606
4 183/29260 0.625
5 13/2310 0.563
6 1040/223839 0.465
7 65/18088 0.359
8 611/232560 0.263
9 13/7140 0.182
10 27/22610 0.119
11 5/6783 0.074
12 23/54264 0.042
13 111/497420 0.022
14 13/124355 0.010
15 53/1279080 0.004
16 5/397936 0.001
17 1/447678 0.0002

Whichever kind of run matters, plug the total number of cards into the table, and that'll tell you the odds of drawing a run with that number.

The total odds of drawing only "Good" cards (and "Talons" as a "Good" card) is 1/84 (1.190%), and the total odds of drawing only "Good" or "Neutral" cards (and "Talons" as a "Good" card) is 19/504 (3.770%)

# Second: The Raw Odds

I've constructed two tables that relates three things:

• The number of "good" draws from the run, as you defined
• The second table counts "Good" or "Neutral" draws
• The total number of draws from the run, good neutral or bad
• The odds of any run having that total number of good draws and total draws.

<x,y> in the first column means <good cards, all cards>, and the second column is a fraction representing the odds of drawing that kind of run, along with a decimal number representing its odds.

The rows highlighted in green are the runs that are relevant to your interests, that were used in the above table: the runs where, aside from the "stop condition" card drawn, all of the other cards were "Good". All of the other runs represent the other possible outcomes, where before hitting the stop card, you also hit at least one other bad or neutral card.

This was generated using a C++ program developed to hash out all possible outcomes, running in 40 seconds. The code for this program can be found here

### "Good or Neutral Only" Runs:

• @Xirema Looking at your code now to verify you handled the conditionals other than Talon, and wow, the angle you took on that versus the method I was thinking of is orders of magnitude simpler to code. And fast enough to compute on the problem size! This answer is great! Jan 20, 2019 at 5:14