MVI B, 0xFFh        ; Move 0xFF or 255 into Reg B
MOV A, B            ; Move Reg B contents to Reg A
;
MVI H, 0x00h        ; Setup our address registers
MVI L, 0x2Fh
MOV Mem, A          ; Move Reg A to memory address 0x002F
;
MVI H, 0x00h        ; Setup our address registers
MVI L, 0x2Fh
MOV C, Mem          ; Move memory address contents 0x002F to Reg C
;
ADD C               ; Add Reg C to Reg A(accumulator)
;
MVI H, 0x00h        ; Setup our address registers 
MVI L, 0x2Fh
ADD Mem             ; Add memory address contents to Reg A
;
MVI H, 0x00h        ; Setup our address registers 
MVI L, 0xA0h
MVI Mem, 0xABh      ; Move immediate value 0xAB to memory address
;
MVI D, 0x04h        ; Move immediate value 0x04 to Reg D
ADD D               ; Add Reg D to Reg A(accumulator)
MVI A, 0x00h        ; Move value 0x00 into Reg A
;
CMP B               ; Compare B to A
;
MVI H, 0x00h        ; Setup our address registers 
MVI L, 0xA0h
CMP Mem             ; CMP Mem
;
RET                 ; Return/End program
                    ; If you don't end your app in RET
                    ; it won't end until it hits the end of it's
                    ; memory, which is 64k. The results are
                    ; undefined, as you will have no idea
                    ; what's in memory between here and there.
