推荐一个非常有用的子程序
将bx寄存器的内容以十进制输出coutbx proc near
pushf
push bx
push ax
push dx
push cx
cmp bx,0
jge $+10
mov dl,45
mov ah,2
int 33
neg bx
call $+9
pop cx
pop dx
pop ax
pop bx
popf
ret
cmp bx,10
jnb $+12
add bx,48
mov dx,bx
mov ah,2
int 33
ret
push bx
mov dx,0
mov ax,bx
mov cx,10
div cx
mov bx,ax
call $-28
pop bx
mov dx,0
mov ax,bx
div cx
add dx,48
mov ah,2
int 33
ret
coutbx endp