lldiv

Calculates the quotient and remainder of the division of a long integer.

Library:LibC
Classification:ANSI
Service:General C Services

Syntax

  #include <stdlib.h> 
   
  lldiv_t lldiv (
      int64_t   number,
      int64_t   demon);
  

Parameters

number

(IN) Specifies the numerator.

denom

(IN) Specifies the denominator.

Return Values

Returns a structure of type lldiv_t.

Remarks

The lldiv_t structure has fields for the quotient and the remainder. It has the following syntax:

  typedef struct
  {
     int64_t   quot;
     int64_t   rem;
  } lldiv_t;
  

See Also