我想换掉2个角色和第1个角色。我的代码是:
INCLUDE Irvine32.inc
.data
array byte "scs212",0
.code
main proc
mov esi,array
mov al,[esi]
inc esi
move bl,[esi]
xchg al,bl
dec esi
move [esi],al
inc esi
move [esi],bl
mov edx, offset array
call WriteString
exit
main ENDP
END main
我这样尝试但没有工作 result = css212
答案 0 :(得分:0)
MOV ESI,offset array ;pointer to first position
MOV AL,[ESI]
INC ESI
MOV BL,[ESI]
XCHG AL,BL
DEC ESI
MOV [ESI],AL
INC ESI
MOV [ESI],BL
INC ESI