Microprocessor PDF
Microprocessor PDF
ASSIGNMENT – 1
AIM :
ALGORITHM :
dosseg
.model small
.data
array db 1,2,3,4,5
result db ?
.code
main proc
mov ax,@data
mov ds,ax
mov cx,5
mov bl,79h
lea si,array
l1:
mov al,[si]
cmp al,bl
jge l2
mov bl,al
l2:
inc si
dec cx
jnz l1
mov result,bl
mov dl,48
mov ah,2
int 21h
mov ah,4ch
int 21h
main endp
end main
OUTPUT :
RESULT :
The program successfully finds the smallest number from the given array and displays it.