.MODEL SMALL
.STACK 64
.DATA
NL DB 0DH,0AH,'$'
.CODE
MAIN PROC
MOV AX,@DATA
MOV DS,AX
MOV AH,01H
INT 21H
MOV BL,AL
MOV AH,09H
LEA DX,NL
INT 21H
MOV DL,BL
CMP BL,41H
JE ALPHA
CMP BL,42H
JE ALPHA
CMP BL,43H
JE ALPHA
CMP BL,44H
JE ALPHA
CMP BL,45H
JE ALPHA
CMP BL,46H
JE ALPHA
JMP OTHERS
ALPHA:
SUB BL,37H
MOV CL,BL
JMP DISP
OTHERS:
SUB BL,30H
MOV CL,BL
DISP:
MOV AH,02H
INT 21H
DEC CL
JNZ DISP
MOV AH,4CH
INT 21H
MAIN ENDP
END MAIN
;*********************************************
; OUTPUT
;*********************************************
;5
;55555