State of Affairs
Tracking the Game Word's Progress
To keep the user informed about the progress of their guesses, it's essential to display both the number of correctly guessed letters and the letters still to be guessed after each attempt.
For this purpose, we will develop the
get_guessed_word function. This function will maintain a
result_list, which represents the current state of the
gameword, including correctly guessed letters and placeholders for the remaining letters.
- Define the
- Create a for loop to iterate through
ias the iterator, utilizing the
range()function for iteration.
- Implement a condition to determine if elements within
gamewordmatch any in
- If the condition is met, append the letter
result_list; otherwise, append
'_ '(including the space).
Everything was clear?