1. .text
  2. .globl main
  3. main: la $t0, spese
  4. loop: lw $t1, ($t0)
  5. add $t2, $t2, $t1
  6. addi $t0, $t0, 4
  7. bnez $t1, loop
  8. sw $t2, result
  9. jr $ra
  10. .data
  11. spese: .word 15, 10, 8, 0
  12. result: .word 0