Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- TITLE Summing an Array
- ;
- ;
- ;
- ;
- ;
- INCLUDE Irvine32.inc
- .data
- intarray DWORD 10000h,20000h,30000h,40000h ; create integer array
- .code
- main PROC
- mov edi,OFFSET intarray ; edi equals offset of the int array
- mov ecx,LENGTHOF intarray
- mov eax,0
- L1:
- add eax,[edi] ; Move pointer into eax
- add edi,TYPE intarray
- loop L1
- CALL DumpRegs
- exit
- main ENDP
- END main
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement