Puzzle 18 – Numbers Game
Andy and Bob are playing a game. Each person writes a positive integer on a slip of paper. The person who wrote the smaller number wins 1 point, unless it is smaller by one, in which case the person who wrote the larger number wins 2 points. The game is fair in the sense that neither player has an advantage, but what strategy is best in the sense that no other strategy can beat it in the long run, and if any different strategy is followed, there is a counter-strategy that can beat it?
Solution will be on Sunday.


Andrew MW, I’ll write later (in the comments to the solution) how I personally got there. Before I do, are you familiar with how to solve systems of linear equations? Particularly, using matrices? Hmmm… nevermind, even if I believe you are, I’ll write something others will understand.
But I’m also interested in the answer to your last question. Comparatively, to solve the problem is easy, to create it… Wow! Andrew, how was that?
PS.: Try the puzzle I described. It is considered a precious gem, and I agree.
Q for Andrew or Joao – How did you figure out the 1:5:4:5:1 ratio?
I couldn’t see my way through this one.
Andrew, did you invent this yourself? If so, that’s a fantastic effort.
Something, I forgot to tell: the existence of my solution excludes the existence of other solutions… it is not difficult to see why.
Are you trying to scare all of your readers, Andrew? No one is going to solve easily your puzzle.
I’m a little burnt from failing your last puzzle, so I’ll try to be more careful this time. But a long tradition imposes that in many cases, my first solution is wrong, so here it is, with enough time for me to disown it before you post the solution Sunday. Before I start, did you heard about the puzzle of the man who had two children, one is a boy born at a Tuesday? What are the chances that he had two boys? When asked what Tuesday had to do with the problem, the puzzle creator answered “everything!”. That was my thought’s food yesterday and was delicious.
To solve your problem, no one can rely on betting in one single number alone because the other will only have to bet on the number above it, to win huge. Trying to out-thinking the adversary doesn’t lead us to any place either: To think “if I play 1, he’ll play 2, then is better if I play 3, what if he changes to 1 thinking that?”…. as you see, recursive thinking is a dead end too. About Mind-reading, it might be a solution for all these, indeed, but I have not your skills, Andrew.
What is left is strategies based on totally random moves. Any mixing of deterministic pattern on those moves will be fatal if perceived, prompting an exploration of that pattern. However, not any random moves will do. It is obvious that anyone who plays only random numbers above 3, will loose if he doesn’t change his game. The safest way I could devised to play the game is through the following method:
Before start, write in sixteen slips of paper, one 1, five 2’s, four 3’s, five 4’s and one 5. Each time is played a round, the slips are shuffled, and one of them at random is handled, to bet the number in it. If the slip are throw away after, rewrite the drawn number in a new slip and mix it with the others, if not, reuse the slip played.
With this system, any bet played by the opponent against them, will produce an average of zero gains for bets from 1 to 5 (Example, if the number 4 is chosen, the average win is -1/16 -5/16 +2*4/16 +0 -2*1/16 = 0). an average loss of 13/16 for a bet of 5 (-1/16 -5/16 -4/16 -5/16 +2*1/16 = -13/16) and a sure loss of 1 for any number above 6.
Since playing with the five numbers until 5 will not produce any average gains, is it safe for the opponent to play any proportion of numbers inside that set? Not really. That proportion of numbers is the only one against which, each individual bet has zero average gain, and where outside bets has average losses. For other proportions, there will be some individual bets with average gain different from zero. Assume that one of these gains is negative (loss). Since the player is able to average his gains to zero by playing in the previous calculated proportions, that means that, if there are negative gains then there must exist some positive gains too. In other words, if player A is playing with a different proportion of numbers than the one I pointed, he is always going to be vulnerable against certain bets, where in average, he’ll loose. Of course, to explore this vulnerability, the player B must change is game style, and became vulnerable too… In the end, there will be a contest of wills and mind reading again, to see who’s first to use the weakness of the other player. I think this puzzle awesome and would have proportionated an amazing contest of programs… the only way some could clearly win would be by weakening himself, attracting a change of posture from the opponent and counter attacking if and when the opponent answered the provocation.