Advertisement
shawonrog

y & Y Right other letter Wrong

Oct 9th, 2018
145
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. .MODEL SMALL
  2. .STACK 100H
  3. .DATA
  4.  
  5. MSG1 DW "INPUT IS RIGHT. $"
  6. MSG2 DW "INPUT IS WRONG. $"
  7.  
  8. .CODE
  9. MAIN PROC
  10.  
  11. MOV AX,@DATA
  12. MOV DS,AX
  13.  
  14. MOV AH,1
  15. INT 21H
  16. MOV BL,AL
  17.  
  18. MOV AH,2
  19. MOV DL,0AH
  20. INT 21H
  21. MOV DL,0DH
  22. INT 21H
  23.  
  24. CMP BL,'Y'
  25. JE OK
  26. CMP BL,'y'
  27. JE OK
  28.  
  29. MOV AH,9
  30. LEA DX,MSG2
  31. INT 21H
  32. JMP END_IF
  33.  
  34. OK:
  35. MOV AH,9
  36. LEA DX,MSG1
  37. INT 21H
  38.  
  39. END_IF:
  40. MAIN ENDP
  41. END MAIN
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement