day 3 part 1

This commit is contained in:
Lucia Ceionia
2023-12-03 02:11:23 -06:00
parent f9d0e13336
commit f805701abf
7 changed files with 634 additions and 2 deletions

View File

@@ -60,7 +60,7 @@ cmp al, 9
jle .got_char
.no_input:
stc ; set CF
jmp .dec_done
jmp .done
.loop:
lodsb
sub al, '0'
@@ -72,8 +72,9 @@ xchg edi,eax
mul ebx
add edi,eax
jmp .loop
clc ; clear CF
.dec_done:
clc ; clear CF
.done:
mov eax,edi
pop edi
pop edx