Search This Blog

Saturday, April 23, 2011

Write Assembly language program To subtract 2 16-bit BCD numbers


; HL = 2435
; DE = 6578


LHLD 6578H ;
XCHG ; DE = 6578
LHLD 2435H ; HL = 2435
MOV A,L
SUB E ;
DAA ;
STA 2000H ;
MOV A,H ;
SBB D ;
DAA ;
STA 2001H ;
HLT ;

No comments:

Post a Comment