Question: You are to write a program in MIPS assembly for use in the SPIM simulator. The program will implement a single-player guessing game which works

You are to write a program in MIPS assembly for use in the SPIM simulator. The program will

implement a single-player guessing game which works as follows:

Program Specifications:

1. The program will ask the player to try to guess the secret number and receive a

numerical input from the player.

2. If the players number does not match the secret number, the program will output a

message to indicate if the number guessed is too high or too low, and ask the player to

enter a new number (go back to step 1) unless the maximum number of tries (10) has

been reached.

3. If the number guessed by the player matches the secret number, a congratulatory

message will be displayed, followed by the number of tries it took the player to guess

the secret number. The program will end at this point.

4. If the maximum number of tries (10) has been reached and the player has not guessed

the secret number, a you lose or similar message will be displayed. The program will

end at this point.

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!