Advertisement
Guest User

Untitled

a guest
Dec 23rd, 2015
294
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.10 KB | None | 0 0
  1. .386
  2. .model flat, stdcall
  3. option casemap :none
  4. include c:\masm32\include\windows.inc
  5. include c:\masm32\include\user32.inc
  6. include c:\masm32\include\kernel32.inc
  7. include c:\masm32\include\msvcrt.inc
  8. include c:\masm32\include\masm32.inc
  9.  
  10. includelib c:\masm32\lib\masm32.lib
  11. includelib c:\masm32\lib\user32.lib
  12. includelib c:\masm32\lib\kernel32.lib
  13. includelib c:\masm32\lib\msvcrt.lib
  14. .data
  15. a db 1,2,3,4,5
  16. b db 1,2,3,4,5
  17. n db 5
  18. r db 2
  19. mestitle db "bbbb", 0
  20. form db "EDI: %u",0
  21.  
  22. .data?
  23. buffer db 512 dup(?)
  24.  
  25.  
  26. .code
  27. Main PROC
  28.  
  29. push offset r
  30. push offset a
  31. push offset b
  32. push offset n
  33. call f
  34. f proc
  35. dec ecx
  36. push ebp
  37. mov ebp, esp
  38. mov ebx, [ebp+12]
  39. mov edx, [ebp+16]
  40. mov ecx, [ebp+20]
  41. mov esi, [ebp+8]
  42. summ:
  43. mov eax, ebx
  44. add eax, esi
  45. mul eax
  46. mov edi, eax
  47. mov eax, edx
  48. add eax, esi
  49. mul eax
  50. mul edi
  51. ;
  52. add ebx, ecx
  53. add edi, ebx
  54. add edi, esi
  55. jcxz summ
  56. f endp
  57. invoke wsprintf, ADDR buffer,ADDR form, edi
  58. invoke MessageBox,0,ADDR buffer,ADDR mestitle,MB_OK
  59. invoke ExitProcess,0
  60. ret
  61. Main ENDP
  62. END Main
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement