Need help.. ASAP.. (tasm)

i am a beginner of assembly language programming particularly on that with TASM.. We are asked to code a program wherein the user will asked to input a character or a word and then it will print the number of characters inputted by the user.. counting number of characters includes the space(s). here's my code. Kindly help me with this matter.. i really dont know how to fix it..

.MODEL SMALL
.STACK 100h
.DATA

CharPrompt DB 'Enter a word or character: $'
DisplayNumChar DB 13,10,'Number of character is.',13,10, '$'


.CODE
start:
mov ax,@data
mov ds,ax
mov dx,OFFSET CharPrompt
mov ah,9
int 21h
mov ah,10
int 21h


mov ax,@data
mov ds,ax
mov dx,OFFSET DisplayNumChar
mov ah,9
int 21h





mov ah,4ch
mov al,0
int 21h

END start


Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories