Assembly language program to Add two numbers input from user

Code:

org 100h
.stack 100h
.data
.code
main proc    
     mov ah,01
     int 21h
     mov bx,ax
     mov ax,0
     mov ah,01
     int 21h
     add ax,bx
     mov cx,ax 
     
     ;for space 6 line
     mov dx,10
     mov ah,02
     int 21h  
     mov dx,13
     mov ah,02
     int 21h
     
     mov dx,cx
     sub dx,48  
     mov ah,02
     int 21h 
     
     mov ah,4ch
     int 21h
    main endp
end main

OUTPUT:




Comments

Popular posts from this blog

8085 Program for two digits subtraction input from user

Assembly language program to display sum of all even numbers between 1 to 100

Assembly language program to input an integer from user and display whether the number is even or odd