Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

c++ Description: This program is part 1 of a larger program. Eventually, it will be a complete Hangman game. . For this part, the program

image text in transcribed
image text in transcribed
c++
Description: This program is part 1 of a larger program. Eventually, it will be a complete Hangman game. . For this part, the program will o Prompt the user for a game number, o Read a specific word from a file, o Loop through and display each stage of the hangman character Trecommend using a counter while loop and letting the counter be the number of wrong guesses. This will help you prepare for next week o Print the final messages of the game. NOTE: Look at the sample run for the prompt, different hangman pictures, and final messages. You must have at least 3 functions other than main: o Function to prompt the user for a game number. o Function to read the appropriate word from the file based on the game number If number is 1, then read the first word . If number is 2, then read the second word and so on o Function to print the correct hangman picture based on the number of wrong guesses The file with the game words is called, word.txt. An example is: moon racecar program cat word Sample Run #1 (bold, underlined text is what the user types): Gome? 3 10 You lost Answer: program Description: This program is part 1 of a larger program. Eventually, it will be a complete Hangman game. . For this part, the program will o Prompt the user for a game number, o Read a specific word from a file, o Loop through and display each stage of the hangman character Trecommend using a counter while loop and letting the counter be the number of wrong guesses. This will help you prepare for next week o Print the final messages of the game. NOTE: Look at the sample run for the prompt, different hangman pictures, and final messages. You must have at least 3 functions other than main: o Function to prompt the user for a game number. o Function to read the appropriate word from the file based on the game number If number is 1, then read the first word . If number is 2, then read the second word and so on o Function to print the correct hangman picture based on the number of wrong guesses The file with the game words is called, word.txt. An example is: moon racecar program cat word Sample Run #1 (bold, underlined text is what the user types): Gome? 3 10 You lost Answer: program

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Marketing The New Profit Frontier

Authors: Ed Burnett

1st Edition

0964535629, 978-0964535626

More Books

Students also viewed these Databases questions

Question

What information is relevant to solve this problem and why?

Answered: 1 week ago