Export (0) Print
Expand All
0 out of 1 rated this helpful - Rate this topic

labs

Calculates the absolute value of a long integer.

long labs(
   long n 
);

Parameter

n
Long-integer value.

Return Value

The labs function returns the absolute value of its argument. There is no error return.

Requirements

Routine Required header Compatibility
labs <stdlib.h> and <math.h> ANSI, Win 98, Win Me, Win NT, Win 2000, Win XP

For additional compatibility information, see Compatibility in the Introduction.

Libraries

All versions of the C run-time libraries.

Example

See the example for abs.

See Also

Data Conversion Routines | Floating-Point Support | abs | _cabs | fabs | Run-Time Routines and .NET Framework Equivalents

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.