Unix |
Unix v6 |
|
ldiv(3) |
ldiv, lrem long division ldiv(hidividend, lodividend, divisor) lrem(hidividend, lodividend, divisor) The concatenation of the signed 16-bit and the unsigned 16-bit is divided by divisor. The 16-bit signed quotient is returned by and the 16-bit signed remainder is returned by Divide check and erroneous results will occur unless the magnitude of the divisor is greater than that of the high-order dividend. An integer division of an unsigned dividend by a signed divisor may be accomplished by quo = ldiv(0, dividend, divisor); and similarly for the remainder operation. Often both the quotient and the remainder are wanted. Therefore leaves a remainder in the external cell No divide check check.
ldiv(3) |