For this assignment write a C++ program where the computer is going to play a game with the user. In this game the computer will randomly pick a "mystery word" from a list of at least 10 "mystery words". The computer will then print out underscore characters that represent each letter of the mystery word. The user will then get to type in 3 letters as guesses. If any of these 3 letters are in the mystery word, then the computer will print those letters along with underscores for any remaining letters not guessed by the user. The user then has 2 chances to guess the entire mystery word.
Here is an example: (The mystery word is "hello")
_ _ _ _ _
The user guesses 3 letters: m, r, l.
_ _ l l _
The user now has 2 chances to guess (type) in the mystery word.
To get full credit on this assignment youmustuse an array. It might be helpful to use two array's, one for the mystery word list (an array of strings) and an array of characters to store the 3 letters the user guesses.
It could be helpful to use functions.
It is helpful (easier) to only deal with lowercase letters in the mystery words.
Be sure to add comment blocks (one at the very start of your source code and one directly above your main function).
Do not use global variables (variables that are declared outside of { }'s such as outside of your main function) and do not use the goto statement. If you use global variables or the goto statement, you will receive an automatic 0 for this programming assignment.