.model small
.stack 512
.data
cad db 9 dup (' '),'$'
var1 db ?
num db ?
aux db ?
.code
.startup
mov var1,0
mov ah,01h
int 21h
sub al,30h
mov num,al
mov al,num
mov bl,10
mul bl
mov aux,al
mov var1,0
mov ah,01h
int 21h
sub al,30h
add aux,al
mov bl,aux
mov num,bl
mov ah,02h
mov dl,'='
int 21h
mov SI,6
bin:
mov Ah,00h
mov Al,num
mov Bl,2
div Bl
mov var1,Ah
mov num,Al
mov dl,var1
add dl,30h
mov cad[SI],dl
cmp num,1
dec SI
jne bin
je out
cmp num,0
jne bin
je out
out:
mov dl,num
add dl,30h
mov cad[SI],dl
mov ah,09h
lea Dx,cad
int 21h
.exit
end
So I got this asm program which when I input two digit numbers it turns them into binary and I want to modify it for three numbers. But I don't know yet much about assembler so I need some help understanding what I should change and what I shouldn't to be able to achieve this. I've tried changing some values but not luck so far.