版主 你看一下我这个错在哪里 我对那位老兄的题感兴趣 但又不好做 你帮忙看一吧
datar segment
de
dw ?
year dw ?
dito
dw 4
dw 100
dw 400
string db 'Please input the year:','$'
string2 db 'The year is a oK!','$'
string3 db 'the year is not ok!','$'
datar ends
code segment
assume cs:code,ds:datar
main proc;....................10
push ds
xor ax,ax
push ax
start:
lea dx,string
mov ah,09h
int 21h
mov dx,0
mov ah,01h
int 21h
mov de, ax;..............20
mov bx,dx
div dito
cmp dx,0
jz
print
mov ax,de
mov dx,bx
div dito+2
jne print
mov ax,de
mov dx,bx;...............30
div dito+4
jz print
jmp print1
print:
lea dx,string2
mov ah,09h
int 21h
jmp start
print1: lea dx,string3
mov ah,09h
int 21h
jmp
start
ret
main endp
code ends
end start