Question: Part 3. Accessing array elements in MIPS: Write a program to find min, maximum, and average value of the elements of an array. (25 points)

Part 3. Accessing array elements in MIPS: Write a program to find min, maximum, and average value of the elements of an array. (25 points) Define an array and state its size in a separate variable as you have done in Part 1. Find minimum, maximum, and average value of the array elements. Use integer arithmetic. Display array elements and results as follows Memory Address Array Element Position (hex) Value (int) 1... Average: ... Max:... Min: ... Hint. syscall with the code value 34 is used for printing integer numbers as a hexadecimal number. Remember that memory address are integer numbers. See the code segment below. # Print the contents of $to as an hexadecimal number. $v0, 34 $a0, $zero, $to syscall li add Part 4. Using MIPS for Mathematical Calculations (25 points) Write a program that prompts the user for one or more integer input values, reads these values from the keyboard, and computes a mathematical formula such as (a different formula may be given by your TA): A= (B*C+D/B-C)%B When the computation is finished, the program should print the result along with an explanatory comment to the user via the display. Note that all is done using integer instructions (no floating point)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
