Output the appropriate number of dashes and spaces to


PLEASE USE PYTHON SPYDER

1) Output a brief description of the game of hangman and how to play.

2) Ask the user to enter the word or phrase that will be guessed (have a friend enter the phrase for you if you want to be surprised). Error check: repeatedly ask for a word or phrase until the input is letters and spaces.

3) Output the appropriate number of dashes and spaces to represent the phrase. Dashes are placeholders for letters.

4) Continuously read guesses of a letter from the user and replace the corresponding dashes if the letter is in the word (replace all occurrences, upper and lower case, of the letter), otherwise report that the user has made an incorrect guess. Error check: only accept letters and spaces.

An incorrect guess is counted as a guess, but a guess that is not letters and spaces is not counted as a guess. If a guess is more than one letter, it is assumed to be a guess of the whole phrase: if the match is perfect (independent of case), the game is won; if not, the game is over as a loss.

5) Each turn you will display the phrase as dashes but with any already-guessed letters filled in, as well as which letters have been incorrectly guessed so far and how many guesses the user has remaining.

Case of original input must be preserved, e.g. an upper-case letter in word/phrase must always be displayed in upper case even if the user guessed using a lower-case letter.

6) Your program should allow the user to make a total of k=6 guesses. After the 6th guess, the game is either won with a correct guess or the game ends as a loss.

7) One run of the program plays the game once. Do not have a loop to restart the game.

Request for Solution File

Ask an Expert for Answer!!
Python Programming: Output the appropriate number of dashes and spaces to
Reference No:- TGS02894581

Expected delivery within 24 Hours