lea dx,buffer mov ah,0ah int 21h mov al,buffer[2] cmp al,'$' jnz compare jmp output
compare: mov al,buffer[1] cmp al,string[0] jl repeat mov string,al lea si,buffer[2] lea di,string[1] mov cl,buffer[1] sub ch,ch cld rep movsb jmp repeat
output: lea dx,out mov ah,09h int 21h lea dx,string[1] mov ah,09h int 21h mov ah,4ch int 21h
main endp
code ends end start
五. 结果分析 1.
2.
3.