Giter VIP home page Giter VIP logo

beggarmypython's Introduction

Does an infinite game of Beggar-My-Neighbour exist? This question has definitely not plagued scientists for millennia. However, in the event that you think you have found a very long game of Beggar My Neighbour, you might wish to run it through a Beggar My Neighbour simulator written in Python. You can see a full list of record holders here: http://www.richardpmann.com/beggar-my-neighbour-records.html

Usage:

python test.py

Output:

Paulhus 1999:
Starting hands: ------------KAQ----J------/-JQQK---K----JK--QA-A-JA--
There were 4791 turns
There were 670 tricks

Kleber 1999:
Starting hands: ---JQ---K-A----A-J-K---QK-/-J-----------AJQA----K---Q
There were 5790 turns
There were 805 tricks

Collins 2006:
Starting hands: A-QK------Q----KA-----J---/-JAK----A--Q----J---QJ--K-
There were 6913 turns
There were 960 tricks

Mann and Wu 2007:
Starting hands: K-KK----K-A-----JAA--Q--J-/---Q---Q-J-----J------AQ--
There were 7157 turns
There were 1007 tricks

Nessler 2012:
Starting hands: ----Q------A--K--A-A--QJK-/-Q--J--J---QK---K----JA---
There were 7207 turns
There were 1015 tricks

Anderson 2013:
Starting hands: --A-Q--J--J---Q--AJ-K---K-/-J-------Q------A--A--QKK-
There were 7225 turns
There were 1016 tricks

Rucklidge 2014:
Starting hands: -J------Q------AAA-----QQ-/K----JA-----------KQ-K-JJK
There were 7959 turns
There were 1122 tricks

Nessler 2021:
Starting hands: ----K---A--Q-A--JJA------J/-----KK---------A-JK-Q-Q-Q
There were 7972 turns
There were 1106 tricks

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.