Hello im using masm to divide two numbers and get a divide overflow error once I execute the file. I don't see why I am getting that output when the quotient is not larger then 16 digits. Why am i getting a overflow error?

Here is the code

title Overflow Program	(overflow.asm)

.model small 
.stack 100h 


main proc
     mov ax,@data
     mov ds,ax
     mov ax,44 ; place 44 in ax reg
     mov bx,2  ; place 2 in bx reg
     div bx ; div 44 by 2 place quotient in ax and remainder in dx
     mov ax,4C00h 
     int 21h 
main endp 
end main
9 Years
Discussion Span
Last Post by Cog7777
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.