ABS.3
Upload User: jnzhq888
Upload Date: 2007-01-18
Package Size: 51694k
Code Size: 1k
Category:

OS Develop

Development Platform:

WINDOWS

  1. ." @(#)abs.3 6.1 (Berkeley) 5/15/85
  2. ."
  3. .TH ABS 3 "May 15, 1985"
  4. .AT 3
  5. .SH NAME
  6. abs - integer absolute value
  7. .SH SYNOPSIS
  8. .nf
  9. .ft B
  10. #include <stdlib.h>
  11. int abs(int fIifP)
  12. .ft R
  13. .fi
  14. .SH DESCRIPTION
  15. .B Abs
  16. returns the absolute value of its integer operand.
  17. .SH SEE ALSO
  18. .BR floor (3).
  19. .SH BUGS
  20. Applying the fIabsfP function to the most negative integer generates a
  21. result which is the most negative integer.  That is, abs(0x80000000)
  22. returns 0x80000000 as a result on a machine with 32-bit ints.  Using the
  23. result in unsigned computations is sound however.