Homework Solution: C ⓘfile:///Users/MRROB/Downloads/Jumblewords%20game.pdf Implement a game that allows a user to guess a jumbled w…

    in python . C ⓘfile:///Users/MRROB/Downloads/Jumblewords%20game.pdf Implement a game that allows a user to guess a jumbled word. Basic requirements 1. Offer a selection of at least 4 different categories of words to guess(the example below shows only 2 choices) Words for each category must be stored in a separate text file-colors.txt, animals.txt, etc. The user should select a category and the appropriate filename constructed in the program-the user should not be aware of the files. Words must be read in and stored in a list Three loops are required 2. 3. 4. 5. .Loop to let the user reguess a word if guessed incorrectly .Loop to let the user play again with a different word from the same category Loop to let the user play again with a different category Example usage RESTART:M:Programming LanguagesPytho Select a category of words to quess 1: color 2: animals Guess the word: lrepup pink Try again Guess the word: 1repup red Iry again! Guess the word: lrepup purple Correct! 1.Give me another vord 2. Give me another category 3. Get me out of here! 霍 머 Jumblewords game.pdf syllabus fall monday-docx Historical Perspective-..xlsx , ー Homework.pdf download (1).jpeg ↓ Show All · ー
    C ⓘfile:///Users/MRROB/Downloads/Jumblewords%20game.pdf Implement a game that allows a user to guess a jumbled word. Basic requirements 1. Offer a selection of at least 4 different categories of words to guess(the example below shows only 2 choices) Words for each category must be stored in a separate text file-colors.txt, animals.txt, etc. The user should select a category and the appropriate filename constructed in the program-the user should not be aware of the files. Words must be read in and stored in a list Three loops are required 2. 3. 4. 5. .Loop to let the user reguess a word if guessed incorrectly .Loop to let the user play again with a different word from the same category Loop to let the user play again with a different category Example usage RESTART:M:Programming LanguagesPytho Select a category of words to quess 1: color 2: animals Guess the word: lrepup pink Try again Guess the word: 1repup red Iry again! Guess the word: lrepup purple Correct! 1.Give me another vord 2. Give me another category 3. Get me out of here! 霍 머 Jumblewords game.pdf syllabus fall monday-docx Historical Perspective-..xlsx , ー Homework.pdf download (1).jpeg ↓ Show All · ー

    Expert Answer

     
    import random lst=[] def shuffled(word):

    in python .

    C ⓘfile:///Users/MRROB/Downloads/Jumblewords%20game.pdf Implement a recreation that allows a user to imagine a jumbled message. Basic requirements 1. Offer a excerption of at lowest 4 opposed categories of messages to imagine(the specimen underneath shows singly 2 selects) Messages coercion each kind must be stosanguine in a unconnected citation refine-colors.txt, animals.txt, ceeseeing. The user should excellent a kind and the alienate refinename deceptive in the program-the user should referable attributable attributable attributable be cognizant of the refines. Messages must be decipher in and stosanguine in a roll Three loops are requisanguine 2. 3. 4. 5. .Loop to suffer the user reimagine a message if imagineed improperly .Loop to suffer the user reproduce-exhibit intermittently with a opposed message from the corresponding kind Loop to suffer the user reproduce-exhibit intermittently with a opposed kind Specimen experience RESTART:M:Programming LanguagesPytho Excellent a kind of messages to quess 1: garbling 2: animals Imagine the message: lrepup pink Try intermittently Imagine the message: 1repup sanguine Iry intermittently! Imagine the message: lrepup purple Correct! 1.Give me another vord 2. Give me another kind 3. Get me extinguished of here! 霍 머 Jumblesignification recreation.pdf syllabus decline monday-docx Historical Perspective-..xlsx , ー Homework.pdf download (1).jpeg ↓ Show All · ー

    C ⓘfile:///Users/MRROB/Downloads/Jumblewords%20game.pdf Implement a recreation that allows a user to imagine a jumbled message. Basic requirements 1. Offer a excerption of at lowest 4 opposed categories of messages to imagine(the specimen underneath shows singly 2 selects) Messages coercion each kind must be stosanguine in a unconnected citation refine-colors.txt, animals.txt, ceeseeing. The user should excellent a kind and the alienate refinename deceptive in the program-the user should referable attributable attributable attributable be cognizant of the refines. Messages must be decipher in and stosanguine in a roll Three loops are requisanguine 2. 3. 4. 5. .Loop to suffer the user reimagine a message if imagineed improperly .Loop to suffer the user reproduce-exhibit intermittently with a opposed message from the corresponding kind Loop to suffer the user reproduce-exhibit intermittently with a opposed kind Specimen experience RESTART:M:Programming LanguagesPytho Excellent a kind of messages to quess 1: garbling 2: animals Imagine the message: lrepup pink Try intermittently Imagine the message: 1repup sanguine Iry intermittently! Imagine the message: lrepup purple Correct! 1.Give me another vord 2. Give me another kind 3. Get me extinguished of here! 霍 머 Jumblesignification recreation.pdf syllabus decline monday-docx Historical Perspective-..xlsx , ー Homework.pdf download (1).jpeg ↓ Show All · ー

    Expert Acceptance

     

    import wild

    lst=[]

    def shuffled(word):
    shuffled_message = ”.join(random.sample(word, len(word)))
    return shuffled_word

    def excellent_category():
    lst.clear()
    menu=”Excellent a kind of messages to imagine!.n1. garblingsn2. animalsn3. fruitsn4. flowers”

    print(menu,end=””)
    ch=int(input())

    if ch==1:
    file=’colors.txt’
    elif ch==2:
    file=’animals.txt’
    elif ch==3:
    file=’fruits.txt’
    elif ch==4:
    file=’flowers.txt’
    else:
    print(“Wrong select!!”)

    f=open(file,’r’)
    coercion message in f:
    lst.append(word.strip())

    def kind():
    word=random.choice(lst)
    shuffle_Word=shuffled(word)
    while True:
    print(“Imagine the message:”,shuffle_Word,end=””)
    guess_word=input()
    if imagine_word==word:
    print(“Correct!”)
    break
    else:
    print(“Try intermittently!”)

    def deep():
    select_category()
    category()

    while True:
    print(“n1.Give me another messagen2.Give me another kindn3.Get me extinguished of here!”)
    choice=int(input())

    if select==1:
    category()
    elif select==2:
    select_category()
    category()
    elif select==3:
    break
    else:
    print(“Wrong select!”)

    main()

    Output:

    Refine and folder structure:

    created txt refines: