汇编HappyNewYear
assume cs:codesg,ds:data data segment db 'Happy New Year!' ;15 bytes db 5 dup(00000010B) ;green color db 0 ;for white space attr db 3 dup(00100100B) ;green bgcolor,red color db 0 db 5 dup(01110001B) ;white bgcolor,blue color data ends codesg segment start: mov ax,data mov ds,ax mov ax,0B800H ;destination mov es,ax mov bx,0 mov cx,15 s: mov al, [bx] mov ah,[bx+15] mov di,bx add di,di mov es:[di],ax ;copy to the destination inc bx loop s mov ax,4300h int 21h codesg ends end start