A python package with different python games
Project description
python-games
Installing
# Linux/macOS
python3 -m pip install -U python-games
# Windows
py -3 -m pip install -U python-games
# Github
pip install git+https://github.com/kevys/python-games.git@main
Quick Example
import games
c = input("Choose rock, paper or scissor > ")
output = games.rps(c)
if output[2] is False:
print(f'Loser, You picked {output[0]}, AI picked {output[1]}')
elif output[2] is True:
print(f'Winner, You picked {output[0]}, AI picked {output[1]}')
elif output[2] == None:
print(f"{output[1]}, {output[0]}")
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
python-games-1.0.4.tar.gz
(3.0 kB
view details)
File details
Details for the file python-games-1.0.4.tar.gz.
File metadata
- Download URL: python-games-1.0.4.tar.gz
- Upload date:
- Size: 3.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a5c6755543ab18b080ba35663744e962bfd6ad030e6ca6a2f5a8529141fc3417
|
|
| MD5 |
53749966f697dee76103271feadac762
|
|
| BLAKE2b-256 |
92d4d044b660af71cc7e2bda3129b5fcff1cd50069f1691bf62a4eea0eee741d
|