Witam
Mam problem z zadaniem chodzi o konwersję temperatury z celsiusza na fahrenheit w asemblerze dokładnie TASM dosbox ale program nie chcę działać proszę o pomoc.
Program prosi o podanie wartości w Celsjuszach ale nie konwertuje ich na Fahrenheit :(
.model small
.stack 100h
.data
crlf db 0dh,0ah,"$"
msg1 db "Enter celcius:","$"
msg2 db "In Fahrenheit:","$"
msg3 db ".","$"
result db ?
c db ?
x1 dw ?
y dw 8
x dw 1
z dw 10
.code
.startup
lea dx,msg1
mov ah,09h
int 21h
mov ah,0ah
int 21h
sub al,30h
mov c,al
lea dx,crlf
mov ah,09h
int 21h
mov al,c
mul x
mov x1,ax
mov al,c
mul y
idiv z
add al,c
add al,32
mov result,al
lea dx,msg2
mov ah,09h
int 21h
mov dl,result
add ah,0ah
int 21h
.exit
mov ax,4C00h
int 21h
end