现在的位置: 首页 > 综合 > 正文

第一个程序:Hello World

2018年11月02日 ⁄ 综合 ⁄ 共 251字 ⁄ 字号 评论关闭
assume cs:code, ds:data, ss:stack

data segment
	f1 db 'Hello World... $'
	
data ends 

stack segment 
	db 200 dup (0)

stack ends

code segment

start:	
		mov ax, data
		mov ds, ax			; setting the dx register		

		lea dx, f1
		mov ah, 09H			; set ah to 09H
		int 21H				; trigger the the 21th interrupt
	
		mov ax, 4c00H
		int 21H

code ends

end start

抱歉!评论已关闭.