Write a program to add two 8-bits numbers 2 store it in a memory location 8820H.

Experiment No 1 : Write a program to add two 8-bits numbers 2 store it in a memory location 8820H. 


Code:

MVI A,F0H;

STA 8818H;

MVI A,56H;

STA 8819;

LXI H,8818H;

MVI C,00H;

MOV A,M;

INX H;

ADD M;

JNC AHEAD;

INR C;

AHEAD: STA 8820H;

MOV A,C;

STA 8821H;

HLT;


Output:



Comments