"""returns the letter the player entered this function makes sure the player entered single letter they haven' guessed before "" while truekeep asking until the player enters valid letter print('guess letter ' guess input(''upper( if len(guess! print('please enter single letter ' elif guess in alreadyguessed print('you have already guessed that letter choose again ' elif not guess isalpha() print('please enter letter ' else return guess if this program was run (instead of imported)run the game if __name__ ='__main__' try main( except keyboardinterrupt sys exit(when ctrl- is pressedend the program after entering the source code and running it few timestry making experimental changes to it the comments marked with (!have suggestions for small changes you can make on your ownyou can also try to figure out how to do the followingadd "category selectfeature and let the player choose what category of words they want to play add selection feature so the player can choose between the hangman and guillotine versions of the game exploring the program try to find the answers to the following questions experiment with some modifications to the code and rerun the program to see what effect the changes have what happens if you delete or comment out missedletters append(guesson line what happens if you change drawhangman(missedletterscorrectletterssecretwordon line to drawhangman(correctlettersmissedletterssecretword) what happens if you change [' 'on line to ['*'] what happens if you change print(join(blanks)on line to print(secretword)hangman and guillotine