Question: 5.3 Write a function (int spe:vO, int sno:v1) PENO(int x[]:a0, N:a1) that will find the sum of the positive even values and the sum of

 5.3 Write a function (int spe:vO, int sno:v1) PENO(int x[]:a0, N:a1)

5.3 Write a function (int spe:vO, int sno:v1) PENO(int x[]:a0, N:a1) that will find the sum of the positive even values and the sum of the negative odd values in an array X of length N. The address of an array "X" is passed in a0. "N", the length of the array, is passed in a1. The function should return two values, 1. The sum of all the positive even elements in the array passed back in vO. 2. The sum of all the negative odd elements in the array passed back in v1. Write a main routine to call PENO and print the results. 5.3 Write a function (int spe:vO, int sno:v1) PENO(int x[]:a0, N:a1) that will find the sum of the positive even values and the sum of the negative odd values in an array X of length N. The address of an array "X" is passed in a0. "N", the length of the array, is passed in a1. The function should return two values, 1. The sum of all the positive even elements in the array passed back in vO. 2. The sum of all the negative odd elements in the array passed back in v1. Write a main routine to call PENO and print the results

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!