LXI 2040
MOV A,M
INX 
CMP M
JNC
MOV A,M
DONE, INX
MOV M,A
RST
