jblog
toc

Hangman

2015-04-10, post № 16

games, programming, Python, #ASCII, #based on terminal, #based on text, #black, #black and white, #game, #guess, #guessing, #guessing game, #hangman, #on terminal, #playable on terminal, #terminal, #terminal game, #terminal output, #text, #text-based, #words

On a recent train ride I made a little Python program to play Hangman.
My version has 7 stages (you could implement more by changing the STAGES variable) and is at best playable if you have someone else who gives you a word (you can also type ‘r’ for a random word, but the list of random words is not very long).

hangman-1.png
hangman-2.png
hangman-3.png
Source code: hangman.py