Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions Hangman.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,9 +101,13 @@
for check in range(len(chosen_word)):
if guess in chosen_word[check]:
display[check] = guess

stage = ''
# Check if guess is not in the chosen word
if guess not in chosen_word:
lives -= 1
#lives[stages]

# Check for no lives and exit the loop
if lives == 0:
print(f"You Loose!, you now have {lives} lives left")
Expand All @@ -113,6 +117,7 @@
# if guess not in chosen_word:
# lives -= 1
print(lives)
print(stages[lives])
print(display)

# create a counter list to use to verify the display list if no more item left
Expand Down