Generate bingo cards for the UEFO EURO 2020.
Cross out teams as they are eliminated from the Euro Cup. The first player to complete their bingo card wins.
worldcupbingo.py by Stian Soiland-Reyes
et al. is licensed under a Creative Commons Attribution 4.0 International License.
Based on a work at https://github.com/stain/worldcupbingo.
If you are not able to run this generation script, you can always use our pre-made 100 bingo cards - but only print it once - do not sell duplicates!
The card (see example bingo card) is drawn randomly according to these rules:
This rota between the groups helps ensure that all cards contain a mixture of ‘good’ and ‘not so good’ teams, so that it is not easy to predict in advance who will win. This also makes it quite unlikely for a 3x4 board to win during the group stages (~ 0.02%).
There is a small chance that several boards would contain the same teams (but possibly printed in a different order). The size of the board has been optimized to 3x4 as a trade-off between the whole bingo game finishing too early and adding some excitement towards the end game. From our experience, the winner(s) will typically be in the early quarter finals if about 40 cards are being played.
This game is most fun playing in a shared space, like a lunch room, so that everyone can track progress on each other’s cards.
If two concurrent matches have the same scheduled kick off (e.g. in quarter finals), then any concurrent bingo winners resulting from either matches are considered to be in a tie, which is resolved depending on which way the matches finish:
a) If both matches complete at the end of second half, then both loosing teams are considered knocked out at the same time (ignoring the wall clock) and the bingo prize is shared.
b) If any of the matches extend into extra-time, then the loser of the match which was extended the least (or not at all) are considered to be knocked out earlier.
c) If both matches extend into penalty kickoffs, then both matches are considered to be finished at the same time and the prize is shared; ignoring the number of penalty kicks needed for the knockout and any eventual coin toss.
Download the latest release from https://github.com/stain/worldcupbingo/releases and make sure you have Python3 installed.
$ python3 worldcupbingo.py -h
worldcupbingo.py [bingos] [columns] [rows] [price]
Generate a Euro 2020 bingo card.
bingos - number of bingo boards to generate. Default: 1
rows - number of rows on bingo board. Default: 4
columns - number of columns on bingo board: Default 3
prise - price to print on card: Default £2/board
The card is printed on stdout, so redirect to a filename of your choice:
$ python worldcupbingo.py >bingo.html
Then open in a browser to print the card:
linux ~ $ gnome-open bingo.html
osx ~ $ open bingo.html
C:\WINDOWS> start bingo.html
You can print as many cards as you like, at any time, as each card is generated independently. To generate many cards in one go (printed on separate pages), add the number of cards as a parameter:
$ python worldcupbingo.py 30 >bingo.html
You can also specify the board size, which might be useful if you are printing particularly few or many cards:
$ python worldcupbingo.py 1 3 3 "$5/board" >bingo.html
To change the board price, specify it as the last parameter:
$ python worldcupbingo.py 1 4 4 100 EUR/board >bingo.html
If you are not able to run the generation script, you can always use our pre-made 100 bingo cards - but only print it once - do not sell duplicates!
If you don’t want to specify these on the command line every time, you can modify these settings within worldcupbingo.py to change the number of teams on a board or the price per board.
DEFAULT_ROWS=4
DEFAULT_COLUMNS=3
DEFAULT_PRICE="£2/board"
To modify the generation for a different cup, edit getGroups()
to reflect the
teams. You may need to add additional flags from Wikipedia to flags = ...
above. You should also modify div.html for the new name of the cup.
Note that the number of rows and columns determines how likely boards are to overlap, for smaller number of groups you should shrink the board, e.g. for the Euros use 3x3.
To verify that players have not printed their own card with more favourable teams, you are advised to keep a copy of the generated HTML and make note of the mapping between the Board ID and the player. If you generate multiple cards, the first page will contain a list of the board IDs for this purpose.
The Board ID is generated as a UUIDv5 SHA-1 hash of the alphabetically sorted list of teams on the board (as UTF-8), with trailing newlines (\n
).
(c) 2010-2021 Stian Soiland-Reyes, Matthew Gamble, Jiten Bhagat, Finn Bacall, Robert Haines
Licensed under the Creative Commons Attribution 4.0 International License.
Contributions welcome!