代码如下,编译执行能得到正确结果,就是在debug中 t到int 10h,就乱了。
求解释
assume cs:code
code segment
s1: db 'Good,better,best,','$'
s2: db 'Never let it rest,','$'
s3: db 'Till good is better,','$'
s4: db 'And better,best.','$'
s: dw offset s1,offset s2,offset s3,offset s4
;offset s1=0,offset s2=12h,offset s3=25h,offset s4=3ah
row: db 2,4,6,8
start: mov ax,cs
mov ds,ax
mov bx,offset s
mov si,offset row
mov cx,4
ok:mov bh,0
mov dh,[si]
mov ah,2
mov dl,0
int 10h; 就是这里
mov dx,[bx]
mov ah,9
int 21h
add bx,2
inc si
loop ok
mov ah,1
int 21h
mov ax,4c00h
int 21h
code ends
end start |