Web Applications
Table Standings
Built by Leandro Magbanua
An Elo ladder for my in-laws' Sunday mahjong table, built to settle who is actually the best — it settled that argument and started four new ones.
Builder email verified
Verification

- Type
- Personal
- Category
- Web Applications
- Published
- Jul 26, 2026
- Updated
- Jul 26, 2026
About this project
- What I built & why
My father-in-law's claim to be the best mahjong player in the family rested entirely on everyone remembering his wins and forgetting his losses, and after two years of marriage I had heard enough. The family plays nearly every Sunday, four seats, eight or nine rotating players. I build reconciliation systems for a living; this was, in the end, a reconciliation problem.
- The problem
There was no record. Results existed as competing oral traditions, and disputes were settled by seniority, which favored exactly one person. It needed a rating that handled rotating players fairly — someone who plays every week shouldn't outrank a better player who comes monthly just on volume — and it had to be readable by people whose phones are for messaging and nothing else.
- What I owned
Everything: the rating math, the little Flask app, the game log, and the role of court stenographer every Sunday, entering results at the table while defending the phone from people who want to see their number before the game is over. I also wrote the two-page methodology document, in Taglish, that nobody has read and everybody cites.
- Technical & product decisions
Elo adapted for four players, scored by finishing position per hand block rather than winner-take-all, so a consistent second place is worth something — that one change is why the ratings feel right to people. Ratings recalculate from the full game log every week instead of updating incrementally, which means a corrected past result quietly reflows all history; I named this the Commissioner's Ruling and it has been invoked twice. And there's a print view, formatted for the bond paper my mother-in-law keeps on the refrigerator, because that refrigerator is the real production environment.
- Hardest challenge
Disputed results. The first version let me edit past games, which meant every dispute became an argument about whether editing had occurred — I am told this is what I get for building an audit system with no audit trail. The log is now append-only with amendment records: the original entry stays, the correction references it, and both are visible. Adopting my own professional standards in my personal life was apparently the hard part.
- Result & impact
One hundred and forty-three recorded sessions over two years. My father-in-law is ranked third. He disputes the methodology — never the data, the methodology — and has twice requested rule changes that would coincidentally favor his style of play, which the commissioner's office has taken under advisement. My mother-in-law, who is ranked first and says the whole thing is silly, checks the refrigerator printout every Monday.