Seol mar théacs é seo: The mathematics of games and gambling