0% found this document useful (0 votes)
4 views1 page

Assembly Code to Print "Hello, WORLD!"

This document contains assembly source code for a program that displays 'Hello, WORLD!' on the screen. It includes the data segment for the message and the code segment that initializes the data segment, sets up a loop to print the message, and returns control to DOS. The program utilizes DOS interrupt 21h for output operations.

Uploaded by

ismail emon
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views1 page

Assembly Code to Print "Hello, WORLD!"

This document contains assembly source code for a program that displays 'Hello, WORLD!' on the screen. It includes the data segment for the message and the code segment that initializes the data segment, sets up a loop to print the message, and returns control to DOS. The program utilizes DOS interrupt 21h for output operations.

Uploaded by

ismail emon
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

; This program displays "Hello, WORLD!

"
Assembly Source Code
Offset .model
model small
Address Machine Code .stack 100h
0000 .data
Data
0000 48 65 6C 6C 6F 2C message db "Hello, WORLD!", 0dh, 0ah, '$'
Segment
(DS) 20 57 4F 52 4C 44
21 0D 0A 24

0000 .code
0000 main PROC
0000 B8 ---- R MOV AX, @data
Initialize
0003 8E D8 DS MOV DS, AX
0005 B9 000A MOV CX, 10 ; LOOP counter
0008 back:
Code
0008 B4 09 MOV AH, 9
Segment Print
(CS) 000A BA 0000 R MOV DX, OFFSET message
message
000D CD 21 INT 21h
000F E2 F7 LOOP back
0011 B8 4C00 Return MOV AX, 4C00h
0014 CD 21 to DOS INT 21h
0016 main ENDP
END main

You might also like