assume cs:code,ds:data,ss:stack
stack segment
dw 0,0,0,0,0,0,0,0
stack ends
data segment
db '1. display '
db '2. brows '
db '3. replace '
db '4. modify '
data ends
code segment
start: mov ax,data
mov ds,ax
mov ax,stack
mov ss,ax
mov sp,10h
mov bx,0
mov cx,4
s:push cx
mov si,0
mov cx,4
s0:mov al,3[bx+si]
and al,11011111b
mov 3[bx+si],al
inc si
loop s0
add bx,16
pop cx
loop s
mov ax,4c00h
int 21h
code ends
end start
編程:將data段中每個單詞的前四個字母改為大寫字母(匯編語言(王爽))
最開始跟蹤時data段的數據如下:

程序運行完畢后,data段的數據如下:

