汇编语言——输入两位数比较大小
生活随笔
收集整理的這篇文章主要介紹了
汇编语言——输入两位数比较大小
小編覺(jué)得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.
源代碼?
code segmentassume cs:codeorg 100h start:jmp bbb msg1 db 10,13,'please input x:','$' msg2 db 10,13,'please input y:','$' x db 0 y db 0 msg3 db 10,13,'x=y','$' msg4 db 10,13,'x>y','$' msg5 db 10,13,'x<y','$'bbb:push cspop dslea dx,msg1mov ah,09hint 21hmov ah,1int 21hsub al,30hmov ah,0mov bl,10mul blmov cl,almov ah,1int 21hsub al,30hmov ah,0add al,clmov byte ptr[x],allea dx,msg2mov ah,09hint 21hmov ah,1int 21hsub al,30hmov ah,0mov bl,10mul blmov cl,almov ah,1int 21hsub al,30hmov ah,0add al,clmov byte ptr[y],almov bl,byte ptr[x]sub al,bljz l1jc l2jmp l3 l1:lea dx,msg3mov ah,9int 21hjmp exit1 l2:lea dx,msg4mov ah,9int 21hjmp exit1 l3:lea dx,msg5mov ah,9int 21h ; jmp exit1exit1:mov ah,4chint 21h code endsend start參考文章
https://zhidao.baidu.com/question/562479802788685844.html
總結(jié)
以上是生活随笔為你收集整理的汇编语言——输入两位数比较大小的全部?jī)?nèi)容,希望文章能夠幫你解決所遇到的問(wèn)題。
- 上一篇: 汇编语言——《分支与循环程序设计》实验报
- 下一篇: AJAX——AJAX请求递归