A computer perfect strategy for 9/5 Triple Bonus Poker Plus

I’m a fan of the Dancer and Daily notation for video poker strategies. There are a couple of things I would change, but other than that, the notation makes the strategies compact and usually quite unambiguous. The notation is close to a computer programming language created for specifying video poker strategies, something readable by both humans and almost by computers; and intended to be followed exactly to achieve best results. A computer can follow such instructions, and a human is supposed to emulate such a computer when playing video poker.

I had always wondered how hard it would be to create a computer perfect strategy for a game in this notation. Some of Bob Dancer’s blog posts on Las Vegas Advisor go through the steps of doing that for various games. He seems to be doing it with the help of commercially-available video poker software. But more importantly, he has amazing skills that he has developed in years of analyzing and playing various video poker games.

In comparison, it’s relatively early in my video poker career, but I have some computer programming skills that I enjoy using for analyzing video poker. So instead of trying to find all the exceptions and confirm them manually, I started writing code to help me with that. I chose 9/5 Triple Bonus Poker Plus, which I was planning to play in a casino soon.

The first part of the work was finding a basic strategy. I had a basic strategy for the game lying around from a few years ago, which I had probably created based on the strategy from Video Poker for Winners. I had modified it somewhat and had already converted it to the Dancer/Daily notation. (I have some code that generates basic strategies for various games, but it's not thoroughly polished yet. So I didn't use my own tool to create a basic strategy from scratch. If I had, it wouldn’t look very different from the basic strategy I started from.) You can find the basic strategy I started from here. It has ~0.0018% to go until becoming computer perfect.

As a side note, I’d like to say that figuring out the best basic strategy for some video poker games is not easy, even using a computer. For example, in the game we’re analyzing here, 9/5 Triple Bonus Poker Plus, AK is better to hold than 234, 234 is better to hold than KJ, KJ is on average better to hold than AKJT, and AKJT is on average better to hold than AK.

That’s a loop! Which means you can’t easily put them in order. Mathematically, there is a best ordering, which while not perfect, would have the maximum return possible among the various orderings (sometimes there are more than one orderings with the best return, all with equal returns). But depending on how complex these loops get, finding the best ordering or orderings may be very time-consuming. It can even take hours on a modern computer. Computer scientists call this problem an NP-hard problem: no fast algorithm has been discovered for it, and there’s a good chance we will never discover a fast algorithm for it and other similar problems.

In the specific case of 9/5 Triple Bonus Poker Plus, the best ordering of the hands above (and other hands they participate in a loop with) appears to be:
        KJ > 78T, 79T > KQ > AKHT > AH > 234, 235, 245
There are exceptions to this order of course, but this order has the highest EV among the various alternative orderings. Trying all the different orders and arriving at this specific order took my laptop computer about two minutes of very intense computation.

For comparison, Wizard of Odds Video Poker Strategy Calculator has:
        AKHT > AH > 234, 235, 245 > KJ > 78T, 79T > KQ
Video Poker for Winners has:
        234, 235, 245, 78T, 79T > KQ, KJ > AKHT > AH
Video Poker for Winners seems to have gone for a simpler strategy. The Wizard of Odds’s tool tries to provide the best basic strategy, but due to some bug or simplification in their code, doesn’t. The Wizard has said such bugs are here to stay, because the original programmer has left the project. (See his comment on Wizard of Vegas forums.)

The difference in return is pretty small, of course. For example, if you replace the ordering of the above options in Wizard of Odds’s strategy with the best ordering of the options, you go from a return of ~99.8008% to a return of ~99.8013%, a ~0.0005% improvement.)

Let’s get back to the main story. I coded in the basic strategy: I wrote a software module that would implement the basic strategy, using utility modules that I had written before. I also had some software I had written earlier that I had used in analyzing video poker strategies published by others, which does two very useful things: a) it finds the exact return of a given strategy; and b) it finds all the hands the strategy misses.

Combining these modules, I got a list of all the hands my basic strategy missed. It was a long list, and I needed a plan to attack it. I decided I’ll sort the hands by the expected value difference (how large of a miss the hold is), and work on them in that order. So even if I don’t get to a computer perfect strategy, I can get close. It was somehow guaranteed that even if had to stop my work, I was using my time the best way I could.

And so it started. I would look at, say, all the hands that the basic strategy rule KH > KQJ9 missed and try to figure out a pattern for all the exceptions where KQJ9 was a better hold. In that case, it looked easy. It appeared that there was always a flush penalty to the KH. But was that the correct rule? Could I say with certainty that KQJ9 would always be the better hold when there was a flush penalty to the KH? And could I say that if there was no flush penalty, KH would always be the better hold? In the language of logic, was the existance of a flush penalty to the KH a necessary and sufficient condition for KQJ9 being a better hold?

It's hard to figure this out manually. Bob Dancer seems to very good at doing it, and I assume some other professional players may be too. You need to check a lot of hands, and apply a lot of logical thinking to make sure you aren’t missing anything. But I could write software instead of doing that work, and that I did. I went and modified my code implementing the basic strategy to have that exact exception. To prefer KQJ9 to KH if KH had a flush penatly. Then I ran the software again, to see if there were any hands that I had missed, or if there were any hands I had overcorrected for (hands that KH would be better to hold than KQJ9, despite having a flush penalty). In this case, there were none, and I had hit the right rule for the exception. This was an easy one.

Things got gradually harder. The hardest rules to figure out were A vs QJ and A vs JT. Many times I would think that I had found the exact rule for an exception, then I would go and implement it just to find out that I had either missed something or overcorrected for something. There were times that I thought the computer perfect strategy may be too complex, and it may be better to stop a little short of it.

Luckily enough, the perfect strategy was not that complex for this game. My software and I figured it out after spending about four hours or so of coding and playing with the rules. Here it is:

RF5; 4-OF-A-KIND; SF5 > RF4

SF4 0i [2345-9TJQ] > FL5 or ST5 > SF4: others (1i or A-low)



RF3: KQJ, QJT ... (KQJ < KK, QQ, JJ when fp or Tp)

KK, QQ, JJ > RF3: others

FL4 > low pair: 22-44

KQJT, QJT9 > SF3+1 [QJ9, JT9] > JT98

low pair: 55-TT > ST4 0hi [2345-789T]

SF3+0 [excludes 234]


SF3 0hi 1i [includes 234] ... (“78T, 79T < KJ)

... (SF3: 2-low < AH)

KH ... (< AHHT, KQJ9 when fp)

AHHT, KQJ9 (< AH with no fp)


SF3 1hi 2i [includes all A-low]

ST4i 2hi [KQT9, KJT9, QJT8, QJ98]


QJ .... (QJ with 8p < A with no fp and no lsp)

.... (QJ with 9p unsuited with A < A with no lsfp)

.... (QJ with 9p suited with A < A with no lsp and no other fp than the 9)

A .... (A with fp and lsp < JT with no fp, 9p, 8p, or 7p)

.... (also A with 7fp and another fp lower than 7 < JT)

JT ... (< KJ when fp and {8p or 7p})

KH KT, QT ... (KT < K when fp)

K, Q, J > SF3−2 > ST4 1i 0h

five new cards

(I also found that the SF=1199 version you can find in some casinos has no strategy differences with the SF=1200 version. You should play them identically.)

After I finished the work, I decided to find out if anyone had ever published a computer perfect strategy for the game. I found that Bob Dancer has a three-post series on the game on the Las Vegas Advisor website, which he had posted in 2020. It can be found here: Part 1, Part 2, and Part 3. Bob Dancer is not providing a compact strategy like mine above, but he goes through the process of figuring out the holds and explaining why each hold is right. He even provides exercise hands.

So I started comparing my work with his. At first glance, it appears that there are some strategy differences between my basic strategy and Bob Dancer’s. For example, his second post has:
22, 33, 44 > JT9 > TT > QJ9 > 55 – 99
while mine has:
22, 33, 44 > JT9, QJ9 > 55 – TT
But this is not a real difference: In practice, you never compare TT to QJ9. If a hand contains both a TT option and a QJ9 option, it must also have QJT9, which is listed higher in the strategy and is preferred to both.

Then you actually run into differences of rules, especially when comparing A to JT or QJ. Bob Dancer’s rules for these appear to be quite different than mine. They are simpler too, at least for A vs QJ. Here are our A vs QJ rules (QJ is generally preferred to A, these are the exceptions):

Bob Dancer’s rules:
QJ < A with no fp when 87 or 86 or any 9;
QJ < A with fp when 97 or 96

My rules:
QJ with 8p < A with no fp and no lsp;
QJ with 9p unsuited with A < A with no lsfp;
QJ with 9p suited with A < A with no lsp and no other fp than the 9

First of all, this proves that Bob Dancer is much better in coming out with simple and compact rules than I am. My rules are harder to remember and harder to apply. Mathematically, his rules and my rules prove to be almost identical though. Although I believe my rules are computer perfect and his miss a few hands (he hasn’t claimed his rules are computer perfect). For example, in the hands Q♠J♦A♣9♣6♣ and Q♠J♦A♣9♣7♣, his rules suggest the ace is the better hold, while my rules suggest QJ is. Putting them through a hand analyzer shows QJ is the better option.

Finally, some of the differences between my rules and Bob Dancer’s rules result from the fact that his definition of straight penalties are a little more relaxed than mine. I treat the term “straight penalty” more strictly. For example, in a hand such as K♠2♦J♣T♣3♣, I consider the king a straight penalty to the JT, while Bob Dancer does so for some games and rules and doesn’t do so for some other games and rules. For more details, see Section (g) in his guest post on this site, where he explains his thinking on this topic in some detail. So, while his exception for JT vs KJ says “JT (< KJ when fp+sp)”, mine says “JT (< KJ when fp and {8p or 7p}”. These are the same rule, except I try to be more strict in using the term “sp”.

I have also posted my computer perfect strategy on a separate page here. Feel free to print it and use it to practice or play the game. I may go and improve it in the future based on what I learned from Bob Dancer’s posts, but for now, it can remain a little more complex that it needs to be.