- Joined
- Aug 4, 2005
- Messages
- 26,019
- Likes received
- 223
- Thanks received
- 133
- Location
- On the rug licking my balls.
Below is a piece of code. If you feel like optimising it then please do. It is purely an exercise and for the hard of thinking (AtW), not a competition. Your resulting code must be assembled via debug and if you use a hex listing (in the case of .386 code for example) then please show your source code and explain any optimisations.
Have fun.
Code:
A 100
mov ax,b800
mov ds,ax
mov ax,30
xor di,di
mov cx,10
ds:
mov [di],al
inc di
inc di
dec cx
cmp cx,0
jne 10e
mov di,20
mov cx,10
mov al,[di]
inc al
cmp al,3a
je 12A
mov [di],al
jmp 118
mov al,30
mov [di],al
dec di
dec di
cmp di,0
je 137
jmp 11E
mov ax,4c00
int 21
N test.COM
RCX
3C
W
Q
Have fun.
Last edited:
14:49



