Advertisement
green1ant

scas demo

Mar 19th, 2019
192
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.85 KB | None | 0 0
  1. org 100h
  2.  
  3. start:
  4.  
  5. ;greeting:
  6. ; mov ah, $09
  7. ;mov dx, greeting
  8. ; int 21h
  9.  
  10. comparison:
  11. mov ax, 'e'
  12. mov di, text
  13. repne scasb
  14. jne not_found
  15.  
  16. found:
  17. mov ah, $09
  18. mov dx, ansYes
  19. int 21h
  20. jmp exit
  21.  
  22. not_found:
  23. mov ah, $09
  24. mov dx, ansNo
  25. int 21h
  26. jmp exit
  27.  
  28. exit:
  29. mov ah, $09
  30. mov dx, press_any_key
  31. int 21h
  32. mov ah, $08
  33. int 21h
  34. ret
  35.  
  36. text db "Gotta guys$"
  37. ;greeting db "Hello!", 13, 10, "$"
  38. inputString db 11, 0, 10 dup (?)
  39. nextLine db 13, 10, "$"
  40. ansYes db "Yes!", 13, 10, "$"
  41. ansNo db "No!", 13, 10, "$"
  42. press_any_key db 13, 10, "Press any key to exit...$"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement