Home | Previous Page | Next Page   Function Descriptions >

decdiv( )

The decdiv( ) function divides two decimal type values.

Syntax

mint decdiv(n1, n2, quotient)   /* quotient = n1 / n2 */
   dec_t *n1;
   dec_t *n2;
   dec_t *quotient;
n1
is a pointer to the decimal structure of the first operand.
n2
is a pointer to the decimal structure of the second operand.
quotient
is a pointer to a decimal structure to contain the quotient of n1 divided by n2.

Usage

The quotient value can be the same as the value of either n1 or n2.

Return Values

0
The operation was successful.
-1200
The operation resulted in overflow.
-1201
The operation resulted in underflow.
-1202
The operation attempted to divide by zero.
Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]