Bingo

Bingo: (not) knowing when to call it quits

January 14, 2016 [updated Feb 3]
[pdf here]


1. Introduction

2. Game mechanics

2.1 Setup

2.2 Gameplay

3. Methodology

4. Results & Discussion

5. Final thoughts


1    Introduction

Like any other first generation 30ish Vietnamese-American son of expatriate parents working in Qatar, I spent Christmas evening in Houston with my brothers and family friends from our time living in Saudi Arabia, who had enlisted us to crash a swanky dinner party at their friend’s. After the dinner, the table was cleared off for some traditional Christmas bingo (did you see my personal history? What do I know about Christmas?).

My luck at bingo has always been notoriously bad and this night was no exception. I lost game after game, rarely even coming close, and as I contemplated when would be a good time to check on dessert, I began to wonder how long the average bingo game lasts. On the drive back to Austin the next day, I brought it up with my brother that it would be fun to build a computational model to answer this question. We discussed data structure and algorithms for a bit before arguing about whether the number of players would affect average game length: is it equivalent to run a single-player game of bingo ten times versus a ten-player game of bingo one time? I argued no, and he argued yes.

It turns out that I was right, and what follows is the model I built as evidence. It provides the average game length in number of turns for a game of bingo relative to how many players are in the game (up to 100): a single-player game on average lasts 41 turns while a 100-player game on average lasts 16 turns. It also shows a monotonic decrease in average bingo game length as the number of players increases.

So in your face, Ryan.

2    Game mechanics

I assume most people are familiar with bingo’s mechanics, but a quick overview of the gameplay serves as a reminder to the nature of the problem to be modeled.

2.1    Setup

Each player in bingo is assigned a card with a 5×5 grid of numbers (this model assumes that each player is only playing a single card), as shown below in (1).

sample bingo card

Each of the five columns are labelled by a letter head B, I, N, G, O; and each row can be assigned a number 1-5, allowing us to refer to positions on the bingo card by coordinate position (i.e. O5 is the bottom right corner of the grid containing 75). There are a total of 75 numbers randomly selected from to fill a card, with bin sizes of 15 corresponding to each column: i.e. column B contains five random numbers from 1-15; I contains five random numbers from 16-30; etc. The numbers need not be sequential as shown in (1), but can occur in any position in their respective column. It should be noted that the N3 square is always a free space, and thus it is irrelevant which number falls in that position.

There are finite number of possible bingo cards. For each of the columns B, I, G and O, there are 15 permute 5 possibilities; because N3 is irrelevant in looking at possible cards, column N has 15 permute 4 possibilities. This results in the following total:

maxCards

Due to the relatively large number of possible cards, I assume that no two players will have identical cards in any game of bingo (i.e. |players| = |cards|). In the model, I consider a maximum number players of 100, as this is sufficient to demonstrate the relevant trends.

In a regular game of bingo, there are 12 win conditions for any given card: each of the 5 columns (i.e. {B1, B2, B3, B4, B5}, {I1, I2, I3, I4, I5}, . . . ), each of the 5 rows (i.e. {B1, I1, N1, G1, O1}, {B2, I2, N2, G2, O2}, . . . ), and the two diagonals ({B1, I2, N3, G4, O5}, {B5, I4, N3, G2, O1}). Only one of these win conditions must be fulfilled in order for a player to win.

2.2    Gameplay

Gameplay proceeds as follows:

(2)   Gameplay process

a. Assign each player a unique card

b. Draw a number 1-75 randomly (and set aside)

c. Mark, on any cards that contain it, this number’s position

d. Repeat (2b) Draw and (2c) Mark steps until a player has fulfilled a win condition (there can be more than one winner)

Together, (2b) Draw and (2c) Mark comprise a TURN.

3    Methodology

The primary goals of the model are to determine the average number of turns needed before there is a winner for a given number of players. To do this, the model considers game setups of different numbers of players, from a single-player game up through a hundred-player game. For each setup with n number of players, one thousand games of bingo are run (i.e. 1,000 single-player bingo games, 1,000 two-player bingo games, . . . ).

For each game, n number of random cards are generated, as well as a random ordering (DRAW ORDER) of the numbers 1-75 for the Draw step of gameplay. For each Draw number in the draw order, cards are checked to see if any have satisfied a win condition. If so, the number of turns that have elapsed (number of Drawn numbers), the game terminates and the next game begins. (Note that because games terminate after the first winner is found, I do not identify whether games have multiple winners.)

If there are no winners for a Drawn number, each card is Marked for that number (recall that number positions are only marked if the card contains the number). This process is Repeated by moving through the draw order until a winner is found.

4    Results & Discussion

For each game setup with a given number of players, histograms were generated from the thousand games data so that it was possible to see how many games ended for each number of turns. These histograms are aggregated in the heatmap in Figure 1, where the x-axis is the number of players in a bingo game, the y-axis is the number of turns before a game ends, and the color indicates how many games terminated in a particular number of turns given a particular number of players: blue indicates a low number of games and red indicates a high number of games.

Towards the right edge of the map, where there are 100 players, we can eyeball that most games end somewhere between 15 and 20 turns (the red band), while virtually no games take more than 30 turns to complete. Conversely, if we look at the left edge of the map, where there is only a single player, most games seem to end in about 40 turns, though there are rare games that end in less than 30 turns, and some that take up to 60 turns. The single-player games are also noticeably different from the hundred-player games in their degrees of variation: while hundred-player games almost always terminate within a narrow range of turns, single-player games do not exhibit this pattern.

This is verified by the average metrics of the data. For each game setup (e.g. number of players), I calculated the mean number of turns for a game to end, the median number of turns, and the standard deviation (s), resulting in Table 1.


Table 1

playersmean turnsmedian turnsstandard deviation
141.48342.09.9563904604
236.11137.08.88069135822
332.8533.07.84445664148
431.26332.07.66927838848
529.24529.07.18212886267
628.31328.06.91672111625
727.71828.06.5143285149
826.83727.06.47444445493
926.08726.06.2330916085
1025.5826.06.12907823412
1124.99825.05.99649864504
1224.8425.05.70038595185
1324.26424.05.88950795907
1423.95224.05.63983120315
1523.58424.05.53307726315
1623.18123.05.62016360972
1723.32924.05.38857671375
1822.37923.05.29427606005
1922.16822.05.24154328419
2022.00322.05.19951834308
2121.71822.05.15853428795
2221.84822.05.18410030767
2321.48122.04.97208598075
2421.51522.05.04319095415
2521.09221.05.0232993142
2621.03821.05.13152569905
2720.91221.04.91571520737
2820.35820.04.76967881518
2920.49721.04.77974800591
3020.49721.04.77556185176
3120.26120.04.83558465958
3220.30521.04.87483076629
3320.06620.04.83235387777
3420.04620.04.54245352205
3520.05520.04.82161539321
3619.48620.04.57644010121
3719.66920.04.70057858141
3819.39520.04.54169296628
3919.51120.04.68891021454
4019.20819.04.39576341493
4119.10919.04.50056874184
4219.15719.04.41093538833
4318.8919.04.72693346685
4418.7719.04.11984222999
4518.70119.04.468064346
4618.87519.04.50259647315
4718.78419.04.34940731595
4818.43919.04.29118619964
4918.51119.04.40407527184
5018.47119.04.5335591978
5118.33918.04.257943048
5218.44319.04.1678232928
5318.14918.04.12780801395
5418.01918.04.30565198315
5518.2819.04.25059995765
5618.10718.04.02014315665
5717.81118.04.01662532482
5818.00618.04.27316791151
5918.21618.04.16645460794
6017.81518.04.06654337245
6117.62818.04.30251275419
6217.66318.04.17461746751
6317.74418.03.95202024286
6417.56918.04.12155783655
6517.68818.04.09422227047
6617.50218.04.13811502982
6717.4317.04.11279710173
6817.42318.03.94817312184
6917.25417.04.2066000523
7017.26117.04.06876873268
7117.47518.04.04195187997
7217.19917.04.19992845177
7316.94217.03.99432547497
7417.1617.03.93934004625
7517.07417.03.99105549949
7616.92517.03.93768650352
7717.10417.03.85294484778
7816.79117.04.01588333994
7916.9217.03.98216021777
8016.90617.03.96625314371
8116.86517.03.88365485078
8216.70717.04.04340833951
8316.78817.03.95057666677
8416.54516.03.94435989737
8516.80517.03.82974868627
8616.68317.03.8176577898
8716.6617.03.74464951631
8816.67717.03.83231927167
8916.4217.03.88633503445
9016.35216.03.77545970711
9116.43517.03.73011729038
9216.36217.03.80801207981
9316.38316.53.96160459915
9416.16216.03.83402608233
9516.20816.03.76280958859
9616.20516.03.82582997531
9716.25616.03.77656775393
9816.17116.03.86493971492
9916.20416.03.74224317756
10016.11516.03.82122689722

As can immediately be seen, the mean number of turns before someone wins a game of bingo decreases monotonically as the number of players increases: a single-player game of bingo will take 41.48 turns on average before the player wins, while only it only takes 16.11 turns on average before there is a winner in a hundred-player game.

Of course, there is no such thing as a fraction of a turn, but we can also look to the median number of turns, which in all cases is virtually identical to the mean number of turns. This is a good indicator (though not a definitive one) that there is a normal distribution for the number of turns required before a winner is found for any given number of players. This is also supported by the heatmap in Figure 1, where a single prominent hot band readily emerges as more players are introduced; notably, this hot band is centered within the heat band, indicating that the mean and median number of turns lies in the middle of the range of turns possible. In other words, a game of bingo can vary towards taking more or fewer turns than average to end, but doesn’t seem to skew one way or another.

Looking further at the standard deviation, s, we see that the number of turns for a game to end varies less if more players are introduced. For a single-player game, s is roughly 10, indicating that the average number of turns for a win is 42 (using the median) with a 10 turn margin – most games take between 32-52 turns to end for a single-player game of bingo. On the other hand, in a hundred-player game of bingo where the median is 16, s is roughly 4, indicating that most games end within 16 turns ±4 turns. In other words, the more players there are, the more likely it is for a game to end within the average number of turns.

Graphing the mean turns vs number of players gives us the graph in Figure 2, which shows us the mean number of turns for a game of bingo to end as a function of the number of players. It essentially tracks the center of the hot band within the heatmap in Figure 1.


Figure 2 confirms what Table 1 shows: the average number of turns decreases monotonically as the number of players increases. Many flights and several hours of coding later, I emerge undeniably victorious over my brother.

5    Final thoughts

Like any battle, though I walked off a victor, it wasn’t without wondering what the cost had been. In my case, it was a long weekend of scripting and tweaking my model before writing up what you have before you. So was it worth it? Besides the fact that I have retroactively won a debate that existed in a different calendar year, I now know more about bingo than when I started, so I certainly count that as a personal victory.

But what is it worth to you? Or as my brother asked after I sent him the graphs: what’s the best bingo strategy? I don’t have much in the way of advice except that it always seems worth it to play more bingo cards, though this advantage may diminish as more players are introduced into the game. Nothing common sense doesn’t already tell you.

However, if the trends I have identified are incorporated into a model that accounts for the cost of bingo cards and what the payout is, it’s not hard to imagine that one could create an optimization algorithm that predicts what the most tactical number of bingo cards to play is.

For the rest of us, though, this is more likely a handy guide to remind us when our luck has run out, and that it’s time to politely thank our Christmas dinner hosts and walk our drunk friends and family home.