Created
February 15, 2022 03:49
-
-
Save shivajichalise/22988bbc32ee8bc5b8723acb2ebe3409 to your computer and use it in GitHub Desktop.
Assembly language program to display a string 'POKHARA UNIVERSITY' character wise using macro to insert space between characters.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
printSpace macro | |
mov dl, ' ' | |
mov ah, 2 | |
int 21h | |
endm | |
disp macro msg | |
mov cx, 12h | |
lea di, msg | |
for: mov dl, [di] | |
mov ah, 02h | |
int 21h | |
printSpace | |
inc di | |
loop for | |
endm | |
.model small | |
.stack 64h | |
.data | |
msg db "POKHARA UNIVERSITY$" | |
.code | |
main proc | |
mov ax,@data | |
mov ds,ax | |
disp msg | |
mov ax, 4c00h | |
int 21h | |
main endp | |
end main |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment