Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Given a file of words, \'words.txt\', the program should first pick a word at ra

ID: 3655725 • Letter: G

Question

Given a file of words, 'words.txt', the program should first pick a word at random and print it to the screen. Then the player starts guessing letters of the word. After each guess the program tells the player how many times that letter appears in the word, and prints it to the screen with all the letters that the player has guessed so far filled in. The game ends when the player guesses every letter in the word or the player makes ten incorrect guesses. Here is a list of the words in file: 100 computer programmer operating system architecture television monitor screen terminal file syllabus pointer variable constant compiler problem solving professional amateur hardware software dictionary encyclopedia string array structure integer float compound condition decision design multiple alternative selection repetition function procedure approximation input assignment statement output illustrate parameter difficult argument expression relation comparison reference value class data member description algorithm keyboard mouse compact printer loop infinite diskette recursion long size array string character order sort search find excellent examination object oriented language feature copy construct destructor multiply remainder addition divide university college north graduate diploma degree bachelor master doctor vacation increment intelligence practice I'm just not sure how to choose one at random. PLEASE HELP ME I WILL BE ETERNALLY GRATEFUL P.S. It has to be done using basic programming in C++

Explanation / Answer

1st program int main () { //variable that stands for the amount of guess from user int TotalGuess; int i; int MaxGuesses; MaxGuesses=6; //guesses of user starts from 0 TotalGuess=0; //variable that stands for the guess of the user char UserGuess; char answer; FILE *inp; char filestrings[SIZE]; //number of game always start at 0 and will be incremented by 1 when user plays more Instructions(); inp=fopen("words.txt", "r"); for(i=0;i
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote