
PROGRAMMING CONCEPTS–II 3-31
MOV BIGGEST, AL ;the biggest number will be in AL
;store it in the location BIGGEST
.EXIT
END
The logic of this program is as follows:
i) The numbers are stored as an array in memory named NUMS. BX is used as a
pointer to this array.
ii) CL contains the count of the numbers (here CL = 0AH).
iii) Initially AL = 0.
iv) AL is compared with each number. If AL is not above or equal to the number in the
array, the bigger number is brought to AL.
v) If AL is above the number in the array, the content of AL is retained as it is.
vi) This is one round of comparison. Then, the pointer (BX) is incremented and count ...