LXI B,-1 ; BC:=(-1); LXI H,1000 ; HL:=1000: LOOP DAD B ; HL:=HL+BC; JNC DONE ; go to DONE if carry equals zero; JMP LOOP ; go to LOOP; DONE EQU $ ; start of routine where the loop exits to when done;