【王爽-汇编语言】第九章实验9

用单循环实现的..

 

assume cs:codesg,ds:datasg
datasg segment
  db 'Welcome to masm!'
  db 02h,02h,02h,02h,02h,02h,02h,02h,42h,42h,42h,71h,71h,71h,71h,71h
datasg ends

codesg segment
start:
    mov ax,datasg
    mov ds,ax
   
    mov ax,0b800h
    mov es,ax
   
    mov di,64
    mov si,0
    mov bx,0820h
    mov cx,16
s: mov   al,ds:[si]
   mov es:[bx+di],al
   inc di
   mov al,ds:[si+16]
    mov es:[bx+di],al
    inc si
    inc di
 loop s
 
 mov ax,4c00h
 int 21h
 codesg ends
 end start    
 

你可能感兴趣的:(c,汇编,语言)