🌐
Microsoft Learn
learn.microsoft.com › en-us › cpp › c-runtime-library › reference › fabs-fabsf-fabsl
fabs, fabsf, fabsl | Microsoft Learn
July 28, 2025 - API reference for fabs, fabsf, and fabsl; which calculate the absolute value of a floating-point value.
🌐
Cppreference
en.cppreference.com › w › c › numeric › math › fabs
fabs, fabsf, fabsl, fabsd32, fabsd64, fabsd128 - cppreference.com
December 20, 2024 - The functions with decimal floating-point parameters are declared if and only if the implementation predefines __STDC_IEC_60559_DFP__ (i.e. the implementation supports decimal floating-point numbers) · If successful, returns the absolute value of arg (\(\small |arg| \)|arg|). The value returned ...
🌐
TutorialsPoint
tutorialspoint.com › c_standard_library › c_function_fabs.htm
C library - fabs() function
The C math library fabs() function accepts the parameter(x) of type double that returns the absolute value of x. This function is defined under the header that calculates the absolute value of a float point number.
🌐
Cplusplus
cplusplus.com › reference › cmath › fabs
Cplusplus
Additional overloads are provided in this header (<cmath>) for the integral types: These overloads effectively cast x to a double (defined for T being any integral type).
🌐
Linux Man Pages
linux.die.net › man › 3 › cabsf
cabsf(3): absolute value of complex number - Linux man page
The cabs() function returns the absolute value of the complex number z. The result is a real number.
🌐
Cppreference
en.cppreference.com › w › c › numeric › complex › cabs
cabsf, cabs, cabsl - cppreference.com
March 26, 2015 - If no errors occur, returns the absolute value (norm, magnitude) of z · Errors and special cases are handled as if the function is implemented as hypot(creal(z), cimag(z))
Find elsewhere
🌐
TutorialsPoint
tutorialspoint.com › c_standard_library › c_function_abs.htm
C library - abs() function
The C stdlib library abs() function is used to returns the absolute value of the specified number, where absolute represents the positive number. This function only returns the positive integer.
🌐
Oreate AI
oreateai.com › blog › a-detailed-explanation-of-the-cc-abs-function-from-principles-to-practical-applications › 98179184802234d17e6a4a7370fbad68
A Detailed Explanation of the C/C++ Abs Function: From Principles to Practical Applications - Oreate AI Blog
January 7, 2026 - The absolute value function abs ... core functionality of this function is to return the absolute value of any integer, which represents its distance from zero on a number line....
🌐
KooR
koor.fr › C › cstdlib › abs.wp
KooR.fr - abs - Langage C
abort abs aligned_alloc (C11) atexit atof atoi atol atoll (C99) at_quick_exit (C11) bsearch calloc div div_t exit _Exit (C99) EXIT_FAILURE EXIT_SUCCESS free getenv labs llabs (C99) ldiv ldiv_t lldiv (C99) lldiv_t (C99) malloc MB_CUR_MAX mblen mbstowcs mbtowc qsort quick_exit (C11) rand RAND_MAX realloc srand strtod strtof strtol strtold strtoll (C99) strtoul strtoull (C99) system wcstombs wctomb La librairie <string.h> La librairie <threads.h> La librairie <time.h>
🌐
Scaler
scaler.com › home › topics › abs() function in c
abs() Function in C - Scaler Topics
March 21, 2024 - Whatever integer value we pass into the absolute function abs(), the absolute value of that integer is the return value of abs() in C.
🌐
O'Reilly
oreilly.com › library › view › c-in-a › 0596006977 › re57.html
fabs - C in a Nutshell [Book]
December 16, 2005 - Obtains the absolute value of a number · The fabs() function returns the absolute value of its floating-point argument x; if x is greater than or equal to 0, the return value is equal to x. If x is less than 0, the function returns -x
Authors   Peter PrinzTony Crawford
Published   2005
Pages   618
🌐
Reddit
reddit.com › r/cpp_questions › difference between abs() and fabs(), and can i replace with each other in the program?? and abs() fn is kinda not working.....
r/cpp_questions on Reddit: Difference between abs() and fabs(), and can i replace with each other in the program?? And abs() fn is kinda not working.....
November 26, 2019 - The C++ standard libraries provide these names, fabsf for float, fabs for double and fabsl for long double, for compatibility with C, so that barring other issues C code that uses these names can be compiled as C++. However, the C++ library provides corresponding overloads of the single name abs, which one should use in C++.