Question: Consider the following MIPS variable declarations: LIST: .word 11, 22, 33, 44, 55, 66, 77, 88, 99 LENGTH: .word 9 EVEN: .word 0 ODD: .word

Consider the following MIPS variable declarations: LIST: .word 11, 22, 33, 44, 55, 66, 77, 88, 99 LENGTH: .word 9 EVEN: .word 0 ODD: .word 0 Note that integer variable LENGTH indicates the number of values stored in integer array LIST. Write a program in C++ and assembly language that uses a loop and a selection statement to count the number of even integers and the number of odd integers in the given LIST, and stores these counts in variables EVEN and ODD, respectively. For the declarations shown above, your program should determine that four of the values in LIST are even, and five of the values are odd. Your program should store these counts in variables EVEN and ODD, respectively. Be sure to test and thoroughly debug your program using a lists

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!