"Hello world!" is a classic, the first program to learn every language is it, but for the Assembly, I feel it's getting started with "Hello world!" Words, it is a bit difficult, for assembly language some of the basic knowledge is no longer said, here on the implementation of the assembly language output "Hello world!"
Data SEGMENT
STRING DB ' Hello wowrld! ', ' $ '
data ENDS
STACK1 SEGMENT PARA STACK
DW 20H DUP (0)
STACK1 ENDS
codes SEGMENT assume Cs:codes , DS :D Atas, Ss:stack1
BEGIN: mov ax, DATA
mov DS, AX-
LEA DX, STRING
mov AH, 9
int 21H
MOV AH, 4CH
int 21H
codes ENDS end
BEGIN
After compiling and succeeding the link builds our executable file, this time output we want "Hello world!" note, to display "Hello world!", you need to execute the executable file in cmd
This article is from the "Late Evening" blog, please be sure to keep this source http://yiluohuanghun.blog.51cto.com/3407300/935340