DATA Mydata
    one: WORD = 1
    n: WORD = 7
    i: WORD = 0
    j: WORD = 0
    k: WORD = 1
END Mydata

PROGRAM Prog1
 loop1:
    LDA   n
    SUB   i
    JMPZ  exit1
    SETV  0
    STA   j
 loop2:
    LDA   i
    ADD   one
    SUB   j
    JMPZ  exit2
    LDA   k
    DCA
    LDA   3
    PUT
    LDA   4
    PUT 
    LDA   5
    PUT
    INC   k
    INC   j
    JMP   loop2
 exit2:
    SETV  13
    PUT
    INC   i
    JMP   loop1
 exit1:
    HALT
END Prog1
