1abs(3C)                  Standard C Library Functions                  abs(3C)
2
3
4

NAME

6       abs, labs, llabs - return absolute value of integer
7

SYNOPSIS

9       #include <stdlib.h>
10
11       int abs(int val);
12
13
14       long labs(long lval);
15
16
17       long long llabs(long long llval);
18
19

DESCRIPTION

21       The abs() function returns the absolute value of its int operand.
22
23
24       The labs() function returns the absolute value of its long operand.
25
26
27       The  llabs() function returns the absolute value of its long long oper‐
28       and.
29

USAGE

31       In 2's-complement representation, the absolute  value  of  the  largest
32       magnitude negative integral value is undefined.
33

ATTRIBUTES

35       See attributes(5) for descriptions of the following attributes:
36
37
38
39
40       ┌─────────────────────────────┬─────────────────────────────┐
41       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
42       ├─────────────────────────────┼─────────────────────────────┤
43       │Interface Stability          │Standard                     │
44       ├─────────────────────────────┼─────────────────────────────┤
45       │MT-Level                     │MT-Safe                      │
46       └─────────────────────────────┴─────────────────────────────┘
47

SEE ALSO

49       attributes(5), standards(5)
50
51
52
53SunOS 5.11                        24 Jul 2002                          abs(3C)
Impressum