Profile

ANSI LIBC | Standard C Programming Reference

ANSI LIBC | Standard C Programming Reference
We compiled the list of important C Programming references in a reference sheet for your convenience. Visit and explore the C Programming Reference Sheet!

libc is the standard C library is the essential part of the C programming laguange that most of the operating systems (Linux, BSD, Windows, MacOX, or whaterver) provide some sort interface to it.

Through libc, programmers can write C code that are portable (compilable) to different operating systems.

If you are using C at any level from Hello World to a super hacker, libc is your companion.

Realizing the importance of libc, we put the list of libc API reference any some examples to help you get it quickly when your forget the APIs. As always, additional resources may be helpful:

List of libc APIs

_Exit terminate the calling process
_longjmp
a64l convert between a 32-bit integer and a radix-64 ASCIIstring
abort cause abnormal process termination
abs return an integer absolute value
acos arccosine function
acosf arccosine function
acosh inverse hyperbolic cosine functions
acoshf inverse hyperbolic cosine function
acoshl inverse hyperbolic cosine function
acosl inverse hyperbolic cosine function
ascii ASCII character set encoded in octal, decimal, and hexadecimal
asctime convert date and time to a string
asctime_r
asin arcsine function
asinf arcsine function
asinh inverse hyperbolic sine function
asinhf inverse hyperbolic sine function
asinhl inverse hyperbolic sine function
asinl arcsine function
assert abort the program if assertion is false
atan arctangent function
atan2 arctangent function
atan2f arctangent function
atan2l arctangent function
atanf arctangent function
atanh inverse hyperbolic tangent functions
atanhf inverse hyperbolic tangent functions
atanhl inverse hyperbolic tangent functions
atanl arctangent function
atexit register a function to run at process termination
atof convert a string to a double
atoi convert a string to an integer
atol
atoll
bcmp compare byte sequences
bsd_signal signal handling with BSD semantics
bsearch binary search a sorted table
cabs absolute value of a complex number
cabsf absolute value of a complex number
cabsl absolute value of a complex number
cacos complex arc cosine
cacosf
cacosh complex arc hyperbolic cosine functions
cacoshf complex arc hyperbolic cosine
cacoshl complex arc hyperbolic cosine
cacosl
calloc a memory allocator
carg calculate the complex argument
cargf
cargl calculate the complex argument
casin complex arc sine
casinf
casinh complex arc hyperbolic sine functions
casinhf complex arc sine hyperbolic
casinhl
casinl complex arc sine
catan complex arc tangents
catanf complex arc tangents
catanh complex arc tangents hyperbolic
catanhf complex arc tangents hyperbolic
catanhl complex arc tangents hyperbolic
catanl
cbrt cube root functions
cbrtf
cbrtl
ccos complex cosine functions
ccosf complex cosine function
ccosh complex hyperbolic cosine functions
ccoshf
ccoshl
ccosl complex cosine function
ceil ceiling value function
ceilf
ceill
cexp complex exponential function
cexpf complex exponential function
cexpl complex exponential function
cimag get imaginary part of a complex number
cimagf
cimagl
clearerr clear indicators on a stream
clock report CPU time used
clock_getcpuclockid obtain ID of a process CPU-time clock
clock_getres clock and time functions
clock_gettime clock and time functions
clock_nanosleep high-resolution sleep with specifiable clock
clock_settime
clog colorized log tail
clogf
clogl
conj complex conjugate functions
conjf
conjl
copysign number manipulation function
copysignf
copysignl
cos cosine function
cosf cosine function
cosh hyperbolic cosine function
coshf
coshl
cosl
cpow complex power function
cpowf complex power function
cpowl complex power function
cproj complex projection functions
cprojf project into Riemann Sphere
cprojl
creal complex real functions
crealf get real part of a complex number
creall get real part of a complex number
csin complex sine functions
csinf
csinh complex hyperbolic sine functions
csinhf
csinhl complex hyperbolic sine
csinl
csqrt complex square root
csqrtf
csqrtl complex square root
ctan surfraw(1) search tools
ctanf
ctanh complex hyperbolic tangent functions
ctanhf complex hyperbolic tangent
ctanhl
ctanl complex tangent function
ctermid generate a pathname for the controlling terminal
ctime transform date and time to broken-down time or ASCII
ctime_r
date write the date and time
difftime compute the difference between two calendar time values
div compute quotient and remainder ofan integer division
drand48 generate uniformly distributedpseudo-random numbers
ecvt convert a floating-point number to a string
erand48
erf error function
erfc complementary error function
erfcl
erff
exit cause the shell to exit
exp
exp2 base-2 exponential function
exp2f
exp2l exp2 exp2f exp2l . base-2 exponentialfunction
expf base10 logarithmic function
expl base10 logarithmic function
expm1 exponential minus 1
fabs absolute value function
fabsf
fclose close a stream
fcvt
fdim function returns the logarithm ofargument __x to base 10
fdimf function returns the logarithm ofargument __x to base 10
fdiml function returns the logarithm ofargument __x to base 10
fdopen associate a stream with a file descriptor
feof test end-of-file indicator on a stream
ferror check and reset stream status
fflush flush a stream
fgetc
fgetpos get current file position information
fgets get a string from a stream
fileno map a stream pointer to a file descriptor
flockfile stdio locking functions
floor Round to integer toward negative infinity.
floorf Round to integer toward negative infinity.
floorl Round to integer toward negative infinity.
fma
fmaf
fmal
fmax
fmaxf
fmaxl
fmin
fminf
fminl
fmod
fmodf
fmodl
fopen
fprintf
fputc
fputs put a string on a stream
fread binary stream input/output
free Display amount of free and used memory in the system
freopen stream open functions
frexp convert floating-point number to fractionaland integral components
frexpf
frexpl
fscanf
fseek reposition a stream
fseeko seek to or report file position
fsetpos set current file position
ftello
ftruncate truncate or extend a file to a specified length
ftrylockfile lock FILE for stdio
funlockfile lock FILE for stdio
fwrite
gcvt convert a floating-point number to a string
getc
getc_unlocked
getchar
getchar_unlocked getc_unlocked, getchar_unlocked, putc_unlocked, putchar_unlocked -stdio with explicit client locking
getdate AME
getenv get value of an environment variable
gets get a string from a stdin stream
getsubopt parse suboption arguments from a string
gettimeofday get / set time
gmtime transform date and time to broken-down time or ASCII
gmtime_r
grantpt grant access to the slave pseudo-terminal device
hypot
hypotf
ilogb return an unbiased exponent
ilogbf
ilogbl get integer exponent of a floating-point value
index locate character in string
initstate
isalnum
isalpha test for an alphabetic character
isascii test for a 7-bit US-ASCII character
isblank
iscntrl test for a control character
isdigit test for a decimal digit
isgraph test for a visible character
islower test for a lowercase letter
isprint test for a printable character
ispunct test for a punctuation character
isspace
isupper
iswalnum test for alphanumeric wide character
iswalpha test for an alphabetic wide-character code
iswblank test for whitespace wide character
iswcntrl test for control wide character
iswdigit test for decimal digit wide character
iswgraph test for graphic wide character
iswlower test for a lowercase letter wide-character code
iswprint test for a printable wide-character code
iswpunct test for a punctuation wide-character code
iswspace test for a white-space wide-character code
iswupper test for an uppercase letter wide-character code
iswxdigit test for a hexadecimal digit wide-character code
isxdigit test for a hexadecimal digit
j0 j0, j0f, j0l, j1, j1f, j1l, jn, jnf, jnl -Bessel functions of the first kind
jn
jrand48
kill send a signal to a process
killpg send signal to a process group
l64a
labs return a long integer absolute value
lcong48 generate uniformly distributed pseudo-random numbers
ldexp
ldexpf
ldexpl
ldiv
lgamma log gamma function
lgammaf
llabs
lldiv
llrint
llrintf
llrintl
llround
llroundf
llroundl
locale description of multilanguage support
log
log10
log10f
log10l
log1p
log1pf
log1pl
log2
log2f
log2l
logb
logbf
logbl
logf
logl
longjmp non-local goto
lrint
lrintf
lrintl
lround round to nearest integer value
lroundf
lroundl
malloc Memory Areas and Using malloc()
mblen get number of bytes in a character
mbstowcs convert a character string to a wide-character string
mbtowc convert a multibyte sequence to a wide character
memccpy copy bytes in memory
memchr find byte in memory
memcmp compare bytes in memory
memcpy copy memory area
memmove copy bytes in memory with overlapping areas
memset fill memory with a constant byte
mkstemp make a unique filename
mktemp create a temporary file or directory
modf extract signed integral and fractional values fromfloating-point number
modff
modfl
nan
nanf return 'Not a Number'
nanosleep suspend process execution for an interval measured in nanoseconds
nearbyint roundto nearest integer
nearbyintl
nextafter
nextafterf
nextafterl nextafter, nextafterf, nextafterl, nexttoward, nexttowardf, nexttowardl -floating-point number manipulation
nexttoward
nrand48
pclose close a pipe stream to or from a process
perror explain error codes
popen initiate pipe streams to or from a process
posix_memalign allocate aligned memory
posix_openpt open a pseudo-terminal device
pow power functions
powf
powl
printf format and print data
ptsname get the name of the slave pseudoterminal
putc put a byte on a stream
putc_unlocked nonlocking stdio functions
putchar put a byte on a stdout stream
putchar_unlocked nonlocking stdio functions
putenv change or add an environment variable
puts Write to a channel
qsort sorts an array
raise send a signal to the executing process
rand display a random numbers
rand_r
random random number generator
realloc
realpath return the canonicalised absolute pathname
remainder remainder function
remove remove a file or directory
remquo remainder and part of quotient
remquol
rename Rename files
rewind reset the file position indicator in a stream
rindex character string operations (LEGACY)
round
roundf
roundl
scalb multiply floating-point numberby integral power of radix (OBSOLETE)
scalbln scalbn, scalbnf, scalbnl, scalbln, scalblnf, scalblnl -multiply floating-point number by integral power of radix
scalblnf
scalbn scalbn, scalbnf, scalbnl, scalbln, scalblnf, scalblnl -multiply floating-point number by integral power of radix
scanf input format conversion
setbuf stream buffering operations
setenv change or add an environment variable
setkey set encoding key (CRYPT)
setlocale set program locale
sigaction software signal facilities
sigaddset POSIXsignal set operations.
sigaltstack set and/or get signal stack context
sigdelset delete a signal from a signal set
sigfillset POSIXsignal set operations.
sighold
sigignore System V signal API
siginterrupt allow signals to interrupt system calls
sigismember test for a signal in a signal set
siglongjmp non-local goto with signal handling
signal ANSI C signal handling
sigpause atomically release blocked signals and wait for interrupt
sigpending get pending signals
sigprocmask examine and change blocked signals
sigqueue queue a signal to a process (REALTIME)
sigrelse
sigset signal management
sigsuspend wait for a signal
sigtimedwait
sigwait select a set of signals
sigwaitinfo wait for queued signals (REALTIME)
sin sine function
sinf sine function
sinh
sinhf
sinhl
sinl
snprintf
sprintf sine functioi
sqrt square root function
sqrtf square root function
sqrtl square root function
srand seeding a random nuber
srand48 seeding a random nuber
srandom seeding a random nuber
strcasecmp case-insensitive string comparisons
strcat concatenate two strings
strchr string scanning operation
strcmp compare two strings
strcoll compare two strings using the current locale
strcpy copy a string
strcspn
strdup duplicate a string
strerror get error message string
strerror_r return string describing error number
strftime format date and time
strlen calculate the length of a string
strncasecmp
strncat
strncmp compare part of two strings
strncpy
strpbrk scan a string for a byte
strptime date and time conversion
strrchr
strspn get length of a substring
strstr locate a substring
strtod convert ASCII string to floating-point number
strtof
strtok
strtok_r
strtol
strtold
strtoll
strtoul
strtoull
strverscmp compare two version strings
strxfrm string transformation
system execute a shell command
tan
tanf
tanh
tanhf
tanhl
tanl
tempnam create a name for a temporary file
tgamma compute gamma() function
tgammaf
tgammal
time get time in seconds
time overview of time and timers
timegm inverses of gmtime and localtime
timer_create create a per-process timer (REALTIME)
timer_delete delete a POSIX per-process timer
timer_getoverrun get overrun count for a POSIX per-process timer
timer_gettime arm/disarm and fetchstate of POSIX per-process timer
tmpfile create a temporary file
tmpnam create a name for a temporary file
toascii convert character to ASCII
tolower
toupper convert letter to upper or lower case
trunc
truncate shrink or extend the size of a file to the specified size
truncf
ungetc push byte back into input stream
unlockpt unlock a pseudoterminal master/slave pair
unsetenv change or add an environment variable
utime change file last access and modification times
va_arg handle variable argument list
va_copy
vfprintf
vfscanf
vprintf format output of a stdargargument list
vscanf format input of a stdarg argument list
vsnprintf print formatted output
vsprintf print formatted output
vsscanf
wcscmp compare two wide-character strings
wcsncmp compare two fixed-size wide-character strings
wcstombs convert a wide-character string to a character string
wctomb convert a wide character to a multibyte sequence
y0 Bessel functions of the second kind
yn
Latest Tech News
Your Notes

Sign in/Sign up

Signing in to our system allows you to post your contributions and vote on the contributions of others. It will also allow you to get extra perts like having your favorites in the cloud and having your persistent personal notes wherever you go. More will be added as we scale up our services.

By signing in to our system, you agree our Member Terms and Conditions


Sign-in with one of the following services

Almost finished!

Please select a screen name for NET SOUP.



 Please send me news and special offers from NET SOUP.

 I have read and accept the Terms of Use.

COMPLIMENTARY EXAMPLES

We have no example yet for this entry


Your Name
Now

Community Contributions and Discussions

Modify your search

View Documentation

Jobs from Indeed