DATA SEGMENT
A DB 10
B DB 10
DATA ENDS
CODE SEGMENT
ASSUME DS:DATA,CS:CODE
START:
MOV AX,DATA
MOV DS,AX
MOV BL,B
CMP BL,A
JNZ L1
MOV AH,00
MOV AL,A
JMP L2
L1: MOV AH,A
MOV AL,B
L2: MOV AH,4CH
INT 21
CODE ENDS
END START
;OUTPUT:->
; R
;AX=0000 BX=0000 CX=0032 DX=0000 SP=0000 BP=0000 SI=0000 DI=0000
;DS=0BE4 ES=0BE4 SS=0BF4 CS=0BF5 IP=0000 NV UP EI PL NZ NA PO NC
;0BF5:0000 B8F40B MOV AX,0BF4
;-T
;
;AX=0BF4 BX=0000 CX=0032 DX=0000 SP=0000 BP=0000 SI=0000 DI=0000
;DS=0BE4 ES=0BE4 SS=0BF4 CS=0BF5 IP=0003 NV UP EI PL NZ NA PO NC
;0BF5:0003 8ED8 MOV DS,AX
;-T
;
;AX=0BF4 BX=0000 CX=0032 DX=0000 SP=0000 BP=0000 SI=0000 DI=0000
;DS=0BF4 ES=0BE4 SS=0BF4 CS=0BF5 IP=0005 NV UP EI PL NZ NA PO NC
;0BF5:0005 8A1E0100 MOV BL,[0001] DS:0001=0A
;-T
;
;AX=0BF4 BX=000A CX=0032 DX=0000 SP=0000 BP=0000 SI=0000 DI=0000
;DS=0BF4 ES=0BE4 SS=0BF4 CS=0BF5 IP=0009 NV UP EI PL NZ NA PO NC
;0BF5:0009 3A1E0000 CMP BL,[0000] DS:0000=0A
;-T
;
;AX=0BF4 BX=000A CX=0032 DX=0000 SP=0000 BP=0000 SI=0000 DI=0000
;DS=0BF4 ES=0BE4 SS=0BF4 CS=0BF5 IP=000D NV UP EI PL ZR NA PE NC
;0BF5:000D 7508 JNZ 0017
;-T
;
;AX=0BF4 BX=000A CX=0032 DX=0000 SP=0000 BP=0000 SI=0000 DI=0000
;DS=0BF4 ES=0BE4 SS=0BF4 CS=0BF5 IP=000F NV UP EI PL ZR NA PE NC
;0BF5:000F B400 MOV AH,00
;-T
;
;AX=00F4 BX=000A CX=0032 DX=0000 SP=0000 BP=0000 SI=0000 DI=0000
;DS=0BF4 ES=0BE4 SS=0BF4 CS=0BF5 IP=0011 NV UP EI PL ZR NA PE NC
;0BF5:0011 A00000 MOV AL,[0000] DS:0000=0A
;-T
;
;AX=000A BX=000A CX=0032 DX=0000 SP=0000 BP=0000 SI=0000 DI=0000
;DS=0BF4 ES=0BE4 SS=0BF4 CS=0BF5 IP=0014 NV UP EI PL ZR NA PE NC
;0BF5:0014 EB08 JMP 001E
;-T
;
;AX=000A BX=000A CX=0032 DX=0000 SP=0000 BP=0000 SI=0000 DI=0000
;DS=0BF4 ES=0BE4 SS=0BF4 CS=0BF5 IP=001E NV UP EI PL ZR NA PE NC
;0BF5:001E B44C MOV AH,4C
;-T
;
;AX=4C0A BX=000A CX=0032 DX=0000 SP=0000 BP=0000 SI=0000 DI=0000
;DS=0BF4 ES=0BE4 SS=0BF4 CS=0BF5 IP=0020 NV UP EI PL ZR NA PE NC
;0BF5:0020 CD15 INT 15