News for hackers. Stuff that matters.
Re:Writing a self-modifying x86 factorial program by unnouinceput on Wednesday December 15, 2021 @10:56AM (#29567730)
Let's see, step by step, if we put 2 in EAX what happens:

Init: EBX = 2; EAX = 2;

Loop: EBX = 1;//gets decremented

CMP EBX, 1;//it's 1 so we exit

Final result is 2. Sounds the edge case is not that of an edge after all

There are no comments on this comment yet.