Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- INCLUDE Irvine32.inc
- .stack 4096
- .data
- INPUT DB 10 DUP (0)
- szam DD 0
- .code
- main PROC
- mov edx, offset INPUT
- call ReadString
- dec eax
- mov ecx, eax
- mov eax, 1
- atalakit:
- movzx ebx, INPUT[ecx]
- sub ebx, 48
- imul ebx, eax
- push edx
- mov edx, szam
- add edx, ebx
- mov szam, edx
- pop edx
- imul eax, 10
- loop atalakit
- movzx ebx, INPUT[ecx]
- sub ebx, 48
- imul ebx, eax
- add szam, ebx
- mov eax, szam
- CALL WriteDec
- INVOKE ExitProcess, 0
- main ENDP
- END main
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement