# Using MARS, write Assembly code (for RISC) that computes average of list of mideterm test scores in # freshman ENGR121 class and return in $v0.
# The list consists of scores from 0 through 100 and is terminated with -1.
# Ignore all other values < 0 and > 100.
#
# sum = count = 0;
# while ( *score != -1) do {
# sum += *score;
# count += 1;
# score += 4;
# }
# average = sum / count;
#
# Inputs :
# $a0 - address of list of scores
# Outputs:
# $v0 - returns the average of the test scores or -1.
# Locals:
# $t0 = score counter
# $t1 = score sum
# $t2 = temp for score
# $t3 = temp
# $t4 = holds terminator marker, -1
#
# scores: .word 95, 92, 85, 100, 81, 151, 90, 75, -85, 99, 82, 79, -1