lldiv_t lldiv (long long int numer, long long int denom);
numer/denom
12
long long int quot; // quotient long long int rem; // remainder
1234567891011
/* lldiv example */ #include <stdio.h> /* printf */ #include <stdlib.h> /* lldiv, lldiv_t */ int main () { lldiv_t res; res = lldiv (31558149LL,3600LL); printf ("Earth orbit: %lld hours and %lld seconds.\n", res.quot, res.rem); return 0; }
Earth orbit: 8766 hours and 549 seconds.