cseg segment
assume cs:cseg
start:
mov ax,3a4fh
mov cx, 16
mov bx, 0
l0:
rol ax,1
test ax,1
jz next
inc bx
next:
loop l0
mov ax,bx
mov bx,10
p0:
xor dx, dx
div bx
xor dx,0e30h
push dx
inc cx
cmp ax,0
jnz p0
p1:
pop ax
int 10h
loop p1
mov ah,4ch
int 21h
cseg ends
end start