I've had a few cocktails but I'll do my best. Using a div instruction, load (e)ax with the number being tested then load cx with the divisor. Then use the instruction - div cx. The quotient will be in ax while the remainder, if any, will be left in dx.
mov cx, 3
mov ax, 31
div cx
You could try this code in debug and watch the registers to see whats going on.
At command line type 'debug'
type 'a'
enter the code above
when done click enter twice then type 'r'
type 't' to execute the next instruction and see the registers change.
In the end ax should be 10 while dx contains the remainder of 1.
Forgive if this makes no sense.
