统计数组中0,1个数程序,求帮改错
DATAS SEGMENTdata1 db 'please input 0OR1',10,13,'$'
data2 db 10,13,'0 de geshu',10,13,'$'
data3 db 10,13,'1 de geshu',10,13,'$'
;此处输入数据段代码
DATAS ENDS
STACKS SEGMENT
;此处输入堆栈段代码
STACKS ENDS
CODES SEGMENT
ASSUME CS:CODES,DS:DATAS,SS:STACKS
START:
MOV AX,DATAS
MOV DS,AX
lea dx,data1
mov ah,09h
int 21h
mov cx,0ah
mov bl,30h
mov bh,30h
asd:mov ah,01h
int 21h
add al,0
jz zxc
jmp qwe
iop:dec cx
jnz asd
jmp yui
zxc:inc bl
jmp fgh
qwe:inc bx
fgh:jmp iop
yui:lea dx,data2
mov ah,09h
int 21h
mov dl,bl
mov ah,02h
int 21h
lea dx,data3
mov ah,09h
int 21h
mov dl,bh
mov ah,02h
int 21h;此处输入代码段代码
MOV AH,4CH
INT 21H
CODES ENDS
END START