An array can be created by using the following statement:
myArray WORD 10, 10, 10, 10
which is equal to
myArray WORD 4 DUP(10)
Offset
Value
0000
10
0002
10
0004
10
0006
10
Assume starts at offset 0.
All offsets are shown on the above.
EAX == 12345678h, (Y/N)
INCLUDE Irvine32.inc
.data
X WORD 1234h
Y WORD 5678h
.code
main PROC
mov eax, X
call WriteHex
exit
main ENDP
END main
INCLUDE Irvine32.inc
.data
X WORD 1234h
Y WORD 5678h
Z DWORD ?
.code
main PROC
mov bx, Y
mov Z, bx
mov bx, X
mov Z+2, bx
mov eax, Z
call WriteHex
exit
main ENDP
END main
Output
Output
Output
12345678h
“I’m not arguing, I’m just explaining why I’m right.”
― Unknown