abs(3) Library Functions Manual abs(3)Name
abs, labs - integer absolute value
Syntax
#include <stdlib.h>
#include <stdlib.h>
long labs(i)
long i;
int abs(i)
int i;
long labs(i)
long i;
Description
The and functions return the absolute value of their integer operand. The labs function does the same for a long int.
Restrictions
Applying the or function to the most negative integer generates a result which is the most negative integer. That is,
abs(0x80000000)
returns 0x80000000 as a result.
See Alsofloor(3m)abs(3)
Check Out this Related Man Page
abs(3C) Standard C Library Functions abs(3C)NAME
abs, labs, llabs - return absolute value of integer
SYNOPSIS
#include <stdlib.h>
int abs(int val);
long labs(long lval);
long long llabs(long long llval);
DESCRIPTION
The abs() function returns the absolute value of its int operand.
The labs() function returns the absolute value of its long operand.
The llabs() function returns the absolute value of its long long operand.
USAGE
In 2's-complement representation, the absolute value of the largest magnitude negative integral value is undefined.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Interface Stability |Standard |
+-----------------------------+-----------------------------+
|MT-Level |MT-Safe |
+-----------------------------+-----------------------------+
SEE ALSO attributes(5), standards(5)SunOS 5.10 24 Jul 2002 abs(3C)
I'm sure this is pretty infantile but I can't figute it out.
How to I load the nVidia driver for SuSE 9.2? I have no idea what the X environment is or how to quit it or how to run the nVidia patch.
Secondly how do I persuade my SuSE 9.3 computer to talk with my Windows XP network.
Linux... (9 Replies)
hi all,
can i get script find file & copy that file with path
for an example
sourse : /home/abc/
destination : /home/backup/
files which need to find : tmp*
copy these files with its absolute path inside
like :- /home/abc/x/y/z/tmp.txt to /home/backup/date/x/y/z/tmp.txt
thanks in... (15 Replies)
Hi Everyone,
I need to invoke the dumpstabs utility on Solaris 10.
OS details :
SunOS frtsunserver 5.10 Generic_127127-11 sun4u sparc SUNW,Sun-Fire-V440
when i key in the command dumpstabs -v it says "dumpstabs not found. (13 Replies)
I have a script in which i want to print absolute path of the same script irrespective of path from where i run script.
I am using
test.sh:
echo "pwd : `pwd`"
echo "script name: $0"
echo "dirname: `dirname $0`"
when i run script from /my/test/dir/struct as ../test.sh the output i... (10 Replies)
Hi,
How can I extract parts from an absolute path?
For example :
The absolute path is /dir1/dir2/dir3/dir4/dir5.I need the relative path starting with directory given as parameter : for instance if the parameter is dir3 then the result should be dir3/dir4/dir5
I need generic solution... (9 Replies)
hi buddies;
i have a file.txt:
Note: All the seperators are SPACE.
192.168.1.1
ParameterObject=1 Speech 1
ParameterObject=2 Speech 1
192.168.1.1
ParamFunction=1 UserID 1 (DEACTIVATED)
Sector=1,Device=2,Unit=3 DeviceId 1
192.168.1.1
FeederCable=2B ... (18 Replies)
Hi,
I'm looking for a command that replaces spaces/tabs with pipe symbol and store the result to the same file instead of routing it to another file.
infile
outfile
Thanks. (11 Replies)
Hello all,
I have an unstructured file with space as delimiter , which I want to structure.
The output file should actually have only 5 columns with tab as delimiter.
The 4th column can have only 3 values ( biological_process , cellular_component , molecular_function )
Here is how the... (12 Replies)