Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
div
eof
Expand Minimize
Important This document may not represent best practices for current development, links to downloads and other resources may no longer be valid. Current recommended version can be found here.

labs 

Calculates the absolute value of a long integer.


long labs(
      long n 
);

Parameters

n

Long-integer value.

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

Routine Required header Compatibility

labs

<stdlib.h> and <math.h>

ANSI, Windows 95, Windows 98, Windows 98 Second Edition, Windows Millennium Edition, Windows Millennium Edition, Windows NT 4.0, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003

For additional compatibility information, see Compatibility in the Introduction.

Libraries

All versions of the C run-time libraries.

See the example for abs.

Community Additions

ADD
Show:
© 2015 Microsoft