Question: In Mips Assembly code. Add comments for easy understanding. . . Task-3 [35 Marks] In this task we will write a program in MIPS assembly
In Mips Assembly code. Add comments for easy understanding.

. . Task-3 [35 Marks] In this task we will write a program in MIPS assembly language that should do the following functionality: Prompt the user to enter a number. It should be a number between 1 and 16. Your program should check the validity of user input and should terminate the program if an invalid number is entered after displaying an appropriate message. Prompt the user again for a number. This time the number should be in the range of 5 to 10. Your program should again check the validity of the input and terminate the program in case of an invalid input. Based on the input provided by the user your program should then display an arithmetic table on the console. A sample run of the program is shown below. The values in bold face represent the user response. The skeleton code is shown below. Make sure that your program MUST use the same functions. No additional function is allowed. You can use either the conventional registers or stack memory for input arguments / return address. #Name: #Roll Number: #Name of program: al-t3.asm #Course Code: #Section: ######### ##### .data #your data segment goes here .text main: #prompt the user to enter table number jal inputNumber COMP 300 Section B Fall 2021 #prompt the user to enter range of table (Note that same function is #used) jal inputNumber #display table jal displayTable li $v0,10 syscall inputNumber: displayTable: ######END OF PROGRAM######## Sample Run Enter table number: 4 Enter range of table: 5 The table is shown below: 4 x 1 = 4 4x2 = 8 4x3 = 12 4 x 4 = 16 4x 5 = 20
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
