ok, i am getting a number from the user and i am storing it in a string... so i will basically have a string filled with zeros until the user enters the number. And after that i will have something like: 1234500000, so what i need to do is shift it over to make it like this: 1000002345, the algorithm is easy, but i am a newbie. Here is what i have so far.
.data
SZ = 50
msg BYTE "Please input the Integer: ",0
bign BYTE SZ DUP('0'),0
.code
main PROC
mov edx, offset bign
mov ecx, SZ
call readstring
mov ecx, eax
mov ebx, SZ
sub ebx, eax
mov edi, edx
mov esi, edx
add esi, ebx
add edi, eax
mov bl, '0'
LP1: mov dl,
mov , dl
mov , bl
inc esi
dec edi
Loop LP1
mov bign, offset esi
exit
main ENDP
END main
.data
SZ = 50
msg BYTE "Please input the Integer: ",0
bign BYTE SZ DUP('0'),0
.code
main PROC
mov edx, offset bign
mov ecx, SZ
call readstring
mov ecx, eax
mov ebx, SZ
sub ebx, eax
mov edi, edx
mov esi, edx
add esi, ebx
add edi, eax
mov bl, '0'
LP1: mov dl,
mov , dl
mov , bl
inc esi
dec edi
Loop LP1
mov bign, offset esi
exit
main ENDP
END main
I don't understand what the code is doing could you explain the algorithm? Too sleepy to decipher the code.
hey! i just got it, but thanks for looking...