Question: 2. (60 points) Write the following script for bash Submit a shell script version of the HI-LO game that uses text data. Call this script

 2. (60 points) Write the following script for bash Submit a

2. (60 points) Write the following script for bash Submit a shell script version of the HI-LO game that uses text data. Call this script hilo". The game should be designed for two players. The program should start by prompting player 1 for a target word. The program should then read a word from the keyboard Once the word is entered, the screen should clear. Then, the game should allow player 2 to repeatedly enter guesses and indicate if the guess is too high, too low, or correct. When player 2 finally guesses player 1's target word, the program should display the number of guesses that player 2 needed The system should track the best performance by player 2 (and write it to a save file). If the number of guesses required by player 2 is the best performance to date, the system should display a message to player 2. Then, the new best performance (number of guesses) should be written to the file along with the current date/time and target word used in that game The script should have an option that allows for the ability to use numbers instead of text. If someone types hilo -n, then your program should read a target number from player 1 and track the guesses from player 2 until correct. This performance should be written to its own save file as well (number of guess, date/time, and target number)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!