Advertisement
Farhana_Zaman

Untitled

Jul 13th, 2023
1,695
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. model small  
  2. .data
  3.     w dw 1,2,3,1,1
  4.        
  5. .code
  6.     main proc
  7.        
  8.         mov ax,@data
  9.         mov ds,ax
  10.        
  11.         xor ax,ax
  12.         lea si,w
  13.         mov cx,5
  14.        
  15.         addnos:
  16.         add ax,[si]
  17.         add si,2
  18.        
  19.         loop addnos
  20.        
  21.         mov dx,ax
  22.         add dx,48
  23.         mov ah,2
  24.         int 21h
  25.        
  26.         main endp
  27.     end main
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement