Solution to Assignment 4 "Hangman" for CS106a