Archived
1
0
Fork 0

solutions

This commit is contained in:
nihonium 2022-03-14 22:52:46 +03:00
parent 6407f8f478
commit de4ee10ee2
Signed by: nihonium
GPG key ID: 0251623741027CFC

46
asm/solutions.md Normal file
View file

@ -0,0 +1,46 @@
# zero
```
xor eax, eax
```
# one
```
xor eax, eax
inc eax
```
# next
```
inc ax
```
# prev
```
dec ax
```
# sum
```
mov dx, ax
add dx, bx
```
# sub
```
mov rdx, rax
sub rdx, rbx
```
# imul
```
imul bl
mov dx, ax
```
# idiv
```
cwd
idiv bx
mov dx, ax
```