All Projects → sepandhaghighi → penney

sepandhaghighi / penney

Licence: MIT license
Penney's Game

Programming Languages

python
139335 projects - #7 most used programming language
Jupyter Notebook
11667 projects
shell
77523 projects
Batchfile
5799 projects

Projects that are alternatives of or similar to penney

kuzusi
breakout for terminal
Stars: ✭ 19 (+35.71%)
Mutual labels:  console-game, console-application
maze
cpp console application vcs example
Stars: ✭ 23 (+64.29%)
Mutual labels:  console-game, console-application
Discord-Study-Bot
Discord-Study-Bot is a Study-Time-based leaderboard system in discord servers. This features an Overall leaderboard and leaderboards based on a Daily, Weekly, and Monthly basis.
Stars: ✭ 20 (+42.86%)
Mutual labels:  fun
mango
A @discord bot that has lots of features 🥭
Stars: ✭ 22 (+57.14%)
Mutual labels:  fun
appliedstats
📊 Methods of Applied Statistics Course Textbook Repository
Stars: ✭ 134 (+857.14%)
Mutual labels:  probability
px
ps and top for human beings
Stars: ✭ 151 (+978.57%)
Mutual labels:  console-application
extreme-carpaccio
Slicing and coding game
Stars: ✭ 116 (+728.57%)
Mutual labels:  fun
zuly
🤖 | Hi, I'm zuly, a brazilian bot! Focused on animes!
Stars: ✭ 45 (+221.43%)
Mutual labels:  fun
observations
Beobachtungen und Betrachtungen rund um das Informatik-Studium an der HSLU
Stars: ✭ 45 (+221.43%)
Mutual labels:  fun
map-replace.js
a VSCode extension that replace selected string with custom JavaScript function.
Stars: ✭ 25 (+78.57%)
Mutual labels:  fun
is-odd-or-even
Determines if a given number is odd or even.
Stars: ✭ 15 (+7.14%)
Mutual labels:  fun
FunVideo
A series of embeddable theme into video, include animation and voice.
Stars: ✭ 19 (+35.71%)
Mutual labels:  fun
recaptcha-unpaid-labor
Make ReCaptcha's "I'm not a robot" text more accurate
Stars: ✭ 15 (+7.14%)
Mutual labels:  fun
perseverance-parachute-generator
Generate your own Perseverance parachute-style secret codes!
Stars: ✭ 17 (+21.43%)
Mutual labels:  fun
birthday.py
🎉 A simple discord bot in discord.py that helps you understand the usage of SQL databases
Stars: ✭ 30 (+114.29%)
Mutual labels:  fun
Undergraduate-in-Statistics
Using Computer with your Statistics Major Course
Stars: ✭ 57 (+307.14%)
Mutual labels:  probability
WPCracker
WordPress pentest tool
Stars: ✭ 34 (+142.86%)
Mutual labels:  console-application
mchmm
Markov Chains and Hidden Markov Models in Python
Stars: ✭ 89 (+535.71%)
Mutual labels:  probability
crazy-canvas
Simple canvas playground
Stars: ✭ 12 (-14.29%)
Mutual labels:  fun
ansiart2utf8
Processes legacy BBS-style ANSI art (ACiDDraw, PabloDraw, etc.) to UTF-8. Escape codes and line endings are processed for terminal friendliness.
Stars: ✭ 32 (+128.57%)
Mutual labels:  console-application

Penney's Game

built with Python3 PyPI version

Overview

Penney's game, named after its inventor Walter Penney, is a binary (head/tail) sequence generating game between two or more players. Player A selects a sequence of heads and tails (of length 3 or larger), and shows this sequence to player B. Player B then selects another sequence of heads and tails of the same length. Subsequently, a fair coin is tossed until either player A's or player B's sequence appears as a consecutive subsequence of the coin toss outcomes. The player whose sequence appears first wins [Wikipedia].

Here we have a friendly clone of this game that I wrote during coronavirus quarantine days.

PyPI Counter
Github Stars
Branch master dev
CI
Code Quality CodeFactor codebeat badge

Installation

Source Code

  • Download and install Python3.x (>=3.5)
    • Select Add to PATH option
    • Select Install pip option
  • Download Version 0.4 or Latest Source
  • Run pip install -r requirements.txt or pip3 install -r requirements.txt (Need root access)
  • Run python3 setup.py install or python setup.py install (Need root access)

PyPI

Easy Install

  • Run easy_install --upgrade penney (Need root access)

Exe Version (Windows)

How to Play

  • Open CMD (Windows) or Terminal (UNIX)
  • Run python -m penney or python3 -m penney (or run executable version)

GIF

Try Penney in Your Browser!

You can play Penney's game online in interactive Jupyter Notebooks via the Binder service! Try it out now! :

Binder

  • Open Notebook.ipynb

Contribution

Changes and improvements are more than welcome! ❤️ Feel free to fork and open a pull request.

Please consider the following :

  1. Fork it!
  2. Create your feature branch (under dev branch)
  3. Add your functions/methods to proper files
  4. Pass all CI tests
  5. Update CHANGELOG.md
    • Describe changes under [Unreleased] section
  6. Submit a pull request into dev (please complete the pull request template)

Issues & Bug Reports

Just fill an issue and describe it. I'll check it ASAP! or send an email to [email protected].

  • Please complete the issue template

Dependencies

master dev
Requirements Status Requirements Status

References

1- Penney, Walter. "Problem 95: penney-ante." Journal of Recreational Mathematics 7 (1974): 321.
2- Zajkowski, Krzysztof. "Penney's game between many players." arXiv preprint arXiv:1212.3973 (2012).
3- Guy, R. K., and John Horton Conway. Winning Ways for your Mathematical Plays. Academic Press, London, 1982.
4- Humble, Steve, and Yutaka Nishiyama. "Humble-Nishiyama Randomness Game-A New Variation on Penney's Coin Game." (2010).

Show Your Support

Star This Repo

Give a ⭐️ if this project helped you!

Donate to Our Project

Bitcoin

1KtNLEEeUbTEK9PdN6Ya3ZAKXaqoKUuxCy

Ethereum

0xcD4Db18B6664A9662123D4307B074aE968535388

Litecoin

Ldnz5gMcEeV8BAdsyf8FstWDC6uyYR6pgZ

Doge

DDUnKpFQbBqLpFVZ9DfuVysBdr249HxVDh

Tron

TCZxzPZLcJHr2qR3uPUB1tXB6L3FDSSAx7

Ripple

rN7ZuRG7HDGHR5nof8nu5LrsbmSB61V1qq

Binance Coin

bnb1zglwcf0ac3d0s2f6ck5kgwvcru4tlctt4p5qef

Tether

0xcD4Db18B6664A9662123D4307B074aE968535388

Dash

Xd3Yn2qZJ7VE8nbKw2fS98aLxR5M6WUU3s

Stellar

GALPOLPISRHIYHLQER2TLJRGUSZH52RYDK6C3HIU4PSMNAV65Q36EGNL

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].