Professional Documents
Culture Documents
217021
Week3 Lab3
Lab Report
Introduction:
I learn CMP and JA commend thanks to our code, we defined whole numbers. Collocated
from to small number. I purpose that obtain the larged number. While I obtain largest number,
two numbers compared each other with CMP command. Finaly I obtain largest number is 96
Experimental Work
TITLE PROG-3(EXE) CMP EXAMPLE
PAGE 60,132
.MODEL SMALL
.STACK 64
.DATA
GRADES DB 69,87,96,45,75
ORG 0008
HIGHEST DB ?
.CODE
MAIN PROC FAR
MOV AX,@DATA
MOV DS,AX
MOV CX,5
;BX OFFSET
SUB AL,AL
;AL IS CLEANED
AGAIN:
JA NEXT
MOV AL,[BX]
NEXT:
INC BX
LOOP AGAIN
MOV HIGHEST AL
MOV AH,4CH
INT 21H
MAIN ENDP
END MAIN