__ goes away
[unix-history] / usr / src / lib / libc / stdlib / ldiv.3
.\" Copyright (c) 1990, 1991 The Regents of the University of California.
.\" All rights reserved.
.\"
.\" This code is derived from software contributed to Berkeley by
.\" Chris Torek and the American National Standards Committee X3,
.\" on Information Processing Systems.
.\"
.\" %sccs.include.redist.man%
.\"
.\" @(#)ldiv.3 5.3 (Berkeley) %G%
.\"
.Dd
.Dt LDIV 3
.Os
.Sh NAME
.Nm ldiv
.Nd return quotient and remainder from division
.Sh SYNOPSIS
.Fd #include <stdlib.h>
.Ft ldiv_t
.Fn ldiv "int num" "int denom"
.Sh DESCRIPTION
The
.Fn ldiv
function
computes the value
.Ar num/denom
and returns the quotient and remainder in a structure named
.Ar ldiv_t
that contains two
.Em long integer
members named
.Ar quot
and
.Ar rem .
.Sh SEE ALSO
.Xr div 3 ,
.Xr math 3
.Sh STANDARDS
The
.Fn ldiv
function
conforms to
.St -ansiC .