diff options
author | Braxton Hall | 2022-10-27 20:52:43 +0000 |
---|---|---|
committer | GitHub | 2022-10-27 20:52:43 +0000 |
commit | 0c3a8d355afe70a3ba593fc3f1ead665abf5bb09 (patch) | |
tree | 342fe38102029f5e237799a077e887a6f3109500 | |
parent | 2310fb9265692aee5b06e2f35830b8ceca193073 (diff) | |
parent | 13e755b6ead4c3f36f708e0213e23e84cb0cc545 (diff) |
Merge pull request #60 from nwoeanhinnogaehr/patch-1
Save 2 bytes in fib.asm
-rw-r--r-- | entries/nwoeanhinnogaehr/fib.asm | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/entries/nwoeanhinnogaehr/fib.asm b/entries/nwoeanhinnogaehr/fib.asm index 26ccf11..729958f 100644 --- a/entries/nwoeanhinnogaehr/fib.asm +++ b/entries/nwoeanhinnogaehr/fib.asm @@ -25,25 +25,25 @@ entry: loop: mov eax,esi push 10 - pop ebp - push ebp - jmp format + mov ecx,esp + jmp skip dw $20 ; e_phentsize dw 1 ; e_phnum +skip: + pop ebp format: cdq div ebp inc ebx - dec esp + dec ecx or edx,'0' - mov [esp],dl + mov [ecx],dl test eax,eax jnz format print: mov al,4 - mov ecx,esp mov edx,ebx mov bl,1 int 0x80 |