Advertisement
salmancreation

if else loop assmbly code

Nov 2nd, 2016
123
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.39 KB | None | 0 0
  1. .MODEL SMALL
  2.  
  3. .DATA
  4.  
  5. .CODE
  6. MAIN PROC
  7.    
  8.     MOV CX,6
  9.    
  10.     MOV AH,2
  11.  
  12.     Digit1:
  13.     MOV DL,'3'
  14.     INT 21H
  15.     CMP CX,4
  16.     JE Digit2
  17.  
  18.     LOOP Digit1
  19.        
  20.     Digit2:
  21.     MOV DL,'2'
  22.     INT 21H
  23.     CMP CX,3
  24.     JE Digit3
  25.  
  26.    
  27.      LOOP Digit2
  28.  
  29.     Digit3:
  30.     MOV DL,'1'
  31.     INT 21H
  32.    
  33.  
  34.        
  35.     MOV AH,4CH
  36.     INT 21H
  37.     MAIN ENDP
  38. END MAIN
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement