C Language Headers and Functions Overview
This PDF contains a reference to commonly used C language header files and their important functions.
--------------------------------------------------
1. <stdio.h> - Standard Input Output
--------------------------------------------------
- printf()
- scanf()
- getchar(), putchar()
- gets(), puts()
- fopen(), fclose()
- fread(), fwrite()
- fprintf(), fscanf()
--------------------------------------------------
2. <stdlib.h> - Standard Library
--------------------------------------------------
- malloc(), calloc(), realloc(), free()
- atoi(), atof(), atol()
- exit(), abort()
- rand(), srand()
- system()
--------------------------------------------------
3. <string.h> - String Handling
--------------------------------------------------
- strlen(), strcpy(), strncpy()
- strcat(), strncat()
- strcmp(), strncmp()
- strchr(), strrchr()
- strstr()
- memset(), memcpy(), memmove(), memcmp()
--------------------------------------------------
4. <math.h> - Math Functions
--------------------------------------------------
- sqrt(), pow()
- sin(), cos(), tan()
- ceil(), floor()
- abs(), fabs()
- log(), log10(), exp()
--------------------------------------------------
5. <ctype.h> - Character Handling
--------------------------------------------------
- isalpha(), isdigit(), isalnum()
- isspace(), isupper(), islower()
- toupper(), tolower()
--------------------------------------------------
6. <time.h> - Time and Date
--------------------------------------------------
- time(), clock()
- difftime()
- localtime(), gmtime()
- strftime(), asctime()
--------------------------------------------------
7. <conio.h> - Console Input Output (Non-standard)
--------------------------------------------------
- getch(), getche()
- clrscr()
- kbhit()
--------------------------------------------------
8. <stdbool.h> - Boolean Type Support
--------------------------------------------------
- bool, true, false
--------------------------------------------------
9. <limits.h> and <float.h> - Constant Limits
--------------------------------------------------
- INT_MAX, INT_MIN, CHAR_MAX, etc.
- FLT_MAX, FLT_MIN, DBL_MAX, etc.
--------------------------------------------------
10. <assert.h> - Diagnostics
--------------------------------------------------
- assert()
--------------------------------------------------
Other useful headers:
- <errno.h> - Error codes
- <signal.h> - Signal handling
- <stdarg.h> - Variable arguments