/hangman

A CLI Hangman game

Primary LanguagePythonThe UnlicenseUnlicense

Hangman

Tests

This Python package exposes a simple CLI hangman game. There are four levels in total: Easy (22.5k words), Medium (74.5k words), Hard (168k words), and Unix (205k words).

The word lists are taken from dolph/dictionary, which, unfortunately, has no license. According to Wikipedia, the Unix dictionary is sourced from Moby Project, a public domain compilation of words. An answer on Unix & Linux Stack Exchange claims that this list varies by each Unix. It is assumed that the rest of the lists do not exceed the threshold of originality and therefore not copyrightable.

Installation

This package only supports Python 3.12 and later. PEP 695 features are not yet used due to mypy and PyCharm's limited support. Any other compatibility with earlier versions are purely incidental.

To play the game, install it with pip using either of the following:

$ git clone https://github.com/InSyncWithFoo/hangman.git
$ pip install -e .
$ pip install "git+https://github.com/InSyncWithFoo/hangman.git"

...then run the pre-built game script called hangman:

$ hangman