比较两个字符串的实现 datarea segment    string1  db   'move the cursor  backward.'string2  db   'move the cursor  backward.'mess1  db  'Match..',13,10,'$'mess2  db  'No match!..',13,10,'$'datarea endsprognam segmentmain proc farassume cs:prognam,ds:datarea,es:datarea         start:push dssub  ax,axpush  axmov ax,datareamov ds,axmov es,axlea si,string1lea di,string2cldmov cx,25repz cmpsbjz   matchlea   dx,mess2jmp  short  disp  match:           lea   dx, mess1disp:          mov   ah,09          int    21h          ret  main      endpprognam  ends          end   start 汇编循环程序的实现 使用15行X16列的表格,输出10H到100H的ASCⅡ码的代码 DATAS SEGMENT ;此处输入数据段代码 DATAS ENDS STACKS SEGMENT ;此处输入堆栈段代码 STACKS ENDS CODES SEGMENT ASSUME CS:CODES,DS:DATAS,SS:STACKS START: MOV AX,DATAS MOV DS,AX sub dx,dx mov ah,02h mov dl,10h rep11: cmp dx,0ffh ja exit mov cx,16 start_loop: int 21h push dx mov dx,0 int 21h pop dx inc dx loop start_loop push dx mov dx,0dh int 21h mov dx,0ah int 21h pop dx jmp rep11 exit: ;此处输入代码段代码 MOV AH,4CH INT 21H CODES ENDS END START  

相关文章:

  • 2021-12-02
  • 2022-12-23
  • 2021-06-05
  • 2021-12-20
  • 2021-11-27
  • 2021-10-22
  • 2021-12-15
猜你喜欢
  • 2021-05-11
  • 2021-11-03
  • 2021-09-17
  • 2021-08-03
  • 2021-10-17
  • 2021-08-17
相关资源
相似解决方案