Pergunta de entrevista da empresa Vanguard

How would you program a hangman-like game?