;; Input consists of a sequence of integers. ;; The first in the sequence denotes how many integers to follows. ;; Write a program that reads in this sequence of numbers ;; and prints out the sum of the integers that follows the first. allocate-registers n i acc loop end testResult a_i one li one 1 read n li i 1 li acc 0 li loop loopL li end endL loopL: sle testResult i n jeqz testResult end read a_i add acc acc a_i add i i one j loop endL: write acc halt