Assembly language program for subtraction of two-8bit number with borrow
Program:
MVI C,00
MVI A,131
MVI B,255
SUB B
JNC L
INR C
L: STA 2050
MOV A,C
STA 2051
HLT
Observation:
INPUT:
A= (83)16=(131)10 , B=(FF)16=(255)10
OUTPUT:
2050:132
2051:1
Result:
Memory
Location
|
Data
value
|
2048
|
131
|
2049
|
255
|
2050
|
132
|
2051
|
01
|
Comments
Post a Comment