Howdy, Stranger!

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

Categories

Check Problem in Code

This program simply prints digits from 0-9, but I dont know what the problem is, it doesnt work, please check it

.model small
.stack 100h
.data
.code

main proc
MOV DL,30H
MOV CX,0AH

AGAIN: MOV AH,02
INT 21H
INC DL
MOV BL,DL

MOV DL,0AH
MOV AH,02
INT 21H
MOV DL,0DH
MOV AH,02
INT 21H

MOV DL,BL
LOOP AGAIN
MOV AX,4C00H

main endp
end main

Comments

  • bunghybunghy Member Posts: 3
    From where I'm standing, it's missing 'int 21h' after 'mov ax, 4c00h'

    : This program simply prints digits from 0-9, but I dont know what the problem is, it doesnt work, please check it
    :
    : .model small
    : .stack 100h
    : .data
    : .code
    :
    : main proc
    : MOV DL,30H
    : MOV CX,0AH
    :
    : AGAIN: MOV AH,02
    : INT 21H
    : INC DL
    : MOV BL,DL
    :
    : MOV DL,0AH
    : MOV AH,02
    : INT 21H
    : MOV DL,0DH
    : MOV AH,02
    : INT 21H
    :
    : MOV DL,BL
    : LOOP AGAIN
    : MOV AX,4C00H
    :
    : main endp
    : end main
    :

  • lastkeylastkey Member Posts: 7
    Yep! Problem is solved, thankyou very much for your help
  • lastkeylastkey Member Posts: 7
    Yep! Problem is solved, thankyou very much for your help
Sign In or Register to comment.