flat assembler
Message board for the users of flat assembler.
Index
> Windows > finding the numbers of negative and positive numbers |
Author |
|
revolution 05 Jun 2020, 08:25
You didn't say exactly what problem you have so I'll wing it from what I see above ...
You print the same MESSAGE twice. I presume the second printf is meant to be MESSAGE2. Also, ccall will corrupt the values in registers eax, ecx, and edx. So the value in edx is now lost after the first ccall. You can save it another register like esi or edi Code: mov edi,edx ccall [printf], MESSAGE, eax ccall [printf], MESSAGE2, edi Code: entry proc_pos_and_neg |
|||
05 Jun 2020, 08:25 |
|
enterprevic 05 Jun 2020, 10:28
revolution wrote: You didn't say exactly what problem you have so I'll wing it from what I see above ... The program doesn't compile from CMD and I'm thinking it's a problem from the code, so I don't really know if it's a problem from the code or my PC |
|||
05 Jun 2020, 10:28 |
|
revolution 05 Jun 2020, 10:33
What error message do you get when you compile?
|
|||
05 Jun 2020, 10:33 |
|
enterprevic 05 Jun 2020, 17:42
revolution wrote: What error message do you get when you compile? I get an error saying it can't run on your PC, and I even tried recompiling assembly programs I compiled earlier and was getting the same error message |
|||
05 Jun 2020, 17:42 |
|
revolution 05 Jun 2020, 22:30
What do you see if you just type fasm at the command prompt? Do you see fasm print the help text?
|
|||
05 Jun 2020, 22:30 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.