DPG came up with an interesting way to engage our interest (or maybe burn time as Christmas drew near) while teaching us about trends down groups and periods in the periodic table: he got us all to play the famous (I think) game of ‘higher or lower’. The rules are simple: A card is placed on the table (or stuck to the whiteboard) face up, and the players have to guess whether the next card, drawn at random, is higher or lower than the one on the board. If you get it wrong, you’re out of the game. If you’re right, you stay in for the next round. The last one remaining wins of course. Most of the mathematically pretentious members of the class (like me) naively played very strictly by the rule of maximising the probability of winning at each round: the risk-averse lot. On the other hand, the riskophiles were partial to going ‘lower’ on the 4 of Spades. Originally I thought it’s always better to play by my method: to long cards lower than 8 and short cards higher than a 8 (for the sake of nomenclature, rather than saying going ‘higher’ or ‘lower’ on a card, I’ll say to ‘long’ or ‘short’ the card – it’s a _bit_ shorter). I didn’t win a single round, but some of the members of the class willing to take risks won one or two mars bars (yes that was what we were playing for…). So what’s going wrong? Does Maths not work?

I eventually came to realise the flaw in the original model I came up with: I thought all that matters is the probability of winning at each round and completely neglected to consider the other players. Eventually I worked out it might sometimes be better to go short on a low card if nobody else is shorting it: there is value in avoiding the crowd. If very few people take the same position as you on a card, if you are correct, you have fewer people to compete against in subsequent rounds so have a higher chance of winning. Cursing myself for having been so stupid and missing out on a mars bar (well, not quite) I set about doing some Maths.

### The Mathematics

Let *n* be the number of different card ‘levels’ in the heirarchy (e.g. 2, 3, 4 … King, Queen, Ace). Normally *n*=13 since suites don’t matter.

Assumption #1:

I start by assuming the heirarchy system is transitive, i.e. if a 3 is higher than a 2 and a 4 is higher than a 3, then a 4 is higher than a 2. Then we can number these levels 1 to *n*: e.g. J=10, Q=11, K=12, A=13. I’m basically renumbering the sequence 2, 3 … Q, K, A as 1, 2, … 13.

Let *x* be the level of the current card that people are playing on. So if the card is a King, *x*=12

The probability (*p*) of the next card being higher than x is (n-x)/n and that of the next card being lower (*p’*) is (x-1)/n. If I were using my original naive method, I’d stop here and at each round work out this probability. If *p* > *p’* I’ll long the card, otherwise I’ll short it. However I need to factor in the other players.

Assumption #2:

This is where I make my second main assumption which is more important and tenuous: I assume that the probability of winning in the end is 1/*m* where *m* is the number of players left in the game at that point. This is essentially assuming that every player left in the game has the same probability of winning.

Let *h* be the number of players who long the card.

The probability of winning (*w*) if you long the card is p*(1/h)

The probability of winning (*w’*) if you short the card is (1-p)*(1/(m-h))

Now we have a better method of assessing which way to go. Since you can wait and see how many other people go high/low on a card before deciding on your own position, this method can work. However a bit more work needs to go into this: calculating this probability is a somewhat difficult task: as it turns out,

w = (n-x)/n*(1/h)

which can’t be done in a short amount of time (I certainly can’t sub values in and get a result very quickly – the dividing by h will always turn out to be a mess since it’ll always be like 13 or 7 or something inconvenient), and the second formula is much worse. One way of making this formula easier is finding how many people would have to long a card for the probability of winning with a long position to be equal to that with a short position (where w = w’): a sort of ‘equilibrium point’ at which it’s equally good to go long as short. w = w’ so

(n-x)/n*(1/h) = (1-(n-x)/n)*(1/(m-h))

Which simplifies to:

h/m = (n-x)/n = p

This is incredibly nice: the percentage of people going high has to equal the probability that going high wins for w to equal w’. In retrospect it was sort of obvious I was going to end up with this anyway but it’s good to see it mathematically. This formula is nicer for me because I find proportions and ratios much easier to think about:

h : m = (n-x) : n

If the card is a 8, x = 7.

h : m = 6 : 12

Even better, if we call the number of players who go low on a round *h’*:

h’ / m = (x – 1) / n = p’

h’ : m = (x-1) : n = 6 : 12

Now that we can quickly calculate h, the number of players who ‘should’ go long, and/or h’, we can work out whether too many people are going long or low. If more people are going long than h, we go short. If more people are going short than h’, we go long. Simple!

### Problem?

Some people might notice that h is on the bottom of the fraction in the expression for *w* and may express concern that h may be 0, and thus the probability of winning if you go long is infinity! I think this doesn’t matter because if you do go long, h becomes 1 and w turns into something sensible.

### Game #2

With the assumptions I’ve made, I can also assess a secondary branch of the game that DPG created to spice things up a bit: he gave us the option of guessing the exact value of the first card to be put on the board. If you play this game, if you guess right you win immediately. If wrong, you lose and are out of the game before it even begins. Let’s examine this version. Clearly the probability of winning (*k’*) is 1/n. If you play the main game, at the beginning the probability of winning (*k*) is 1/m by assumption 2. The decision of which game to play is thus fairly obvious. For my class, k’ = 1/13 and k is about 1/15. The alternative would have been a good option after all, despite my gut instincts!

### Meh this is pointless

Ultimately this is probably a flawed model since assumption #2 is most likely wrong but it does highlight the importance of considering the entire game before launching into playing it by some naively constructed strategy like I did… Perhaps the next step would be to try to model how the rest of the class behaves with some sort of probability distribution and come up with a formula for what to do without seeing what everyone else is doing. Or assumption #2 should be reconsidered. Maybe some system of card counting should be factored in, just for fun! But all that takes effort…

what if the same number comes up again? is that higher or lower or neither and everyone loses? :D

Dr Gamblin’ just ignored a repeated card. If there were the possibility of a repeated number affecting the results, of course the formula would have to be reconsidered :D

Actually, Gamblin said everyone lost if the card were the same….

at least in the first rounds

I’m pretty sure there was a repeated card and Gamblin just went ‘meh’ (or something to that effect) and continued