Question: Problem: Given an array of integers, calculate: 1)How many positive numbers are in the array? 2) How many zeros are in the array? 2) Sum


Problem: Given an array of integers, calculate: 1)How many positive numbers are in the array? 2) How many zeros are in the array? 2) Sum of all the positive numbers in the array *NOTE: Use the partial code that is given here in MIPS. Use syscall for writing out the results Show your results in MARS. Here a C code representation of Array is displayed. main () \{ int i, size =8; int arr[8]={12,1,8,0,6,85, MIPS partial code: . text globl main main: \# some initialization is done below. You need to complete it. la $s0, size initialize registers lw $s1,0($s0)$s1= size
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
