C++ Standard Header Files and Their Functions

- November 24, 2017
      In this article, you will find a standard list of C++ header files (with their brief instruction & uses). Each header file have their functions. These functions are called built-in functions of programming language that are used for different kinds of purposes. Before using these functions we should have knowledge about them. So read this article completely to clear the concept about C++ header files & their functions. 
C++ header files and their functions

What are built-in Functions

      The built-in functions are part of the C++ programming language. These are ready-made small program (or functions) in C++. The built-in functions of C++ (or C) are declared in different header files. C++ provides many built-in functions to solve various types of problems. The programmer uses built-in functions in writing program to perform various tasks. This saves the rogrammer’s time from writing his/her own functions. It is also reduce the source code of the program.
      The built-in functions contains in a header file of C++ programming language. Before using them in the program we have to declare header file that have these functions. For example, the "canio.h" header file must be declared before using "clrscr();" function.

1. The "canio.h" header file

      The word “conic" stands for console input/output. The “conio.h” header file contains various basic input and output built-in functions. Some commonly used functions of this header file are as follows:

2. The "stdio.h" Header File

      The word “stdio” stands for standard input/output. This header file contains various standard input and output functions. These functions are used to get input from the input device and to print/display the output on the output device. The most important and commonly used functions of 'stdio.h' header file are as follows:
  1. The getchar( ) Function
  2. The putchar( ) Function
  3. The gets( ) Function
  4. The puts( ) Function

3. The "math.h" Header File

      This header file contains various mathematical functions. These functions are used to perform mathematical operations. The most important and commonly used functions of this header file are given below:
  1. The abs( ) Function
  2. The fabs( ) Function
  3. The sqrt( ) Function
  4. The pow( ) Function
  5. The floor( ) Function
  6. The ceil( ) Function
  7. The fmod( ) Function
  8. The cos( ) Function
  9. The sin( ) Function
  10. The tan( ) Function
  11. The log( ) Function
  12. The log10() Function

4. The "ctype.h" Header File

      This header tile contains various built-in functions that are used to find out the types of different characters or values. It also contains functions used to convert lowercase letters to uppercase letters and vice versa. The most important and commonly used functions of this header file are as follows:
  1. The isalpha() Function
  2. The isalnum() Function
  3. The isdigit() Function
  4. The isxdigit() Function
  5. The islower() Function
  6. The isupper() Function
  7. The isascii() Function
  8. The isspace() Function
  9. The isprint() Function
  10. The iscntrl() Function 
  11. The ispunct() Function
  12. The toascii() Function
  13. The tolower() Function
  14. The toupper() Function

5. The "string.h" Header File

      This header file contains the string related built-in functions. These functions are used to process strings. The most important and commonly used string functions of this header file are described as under:
  1. The strlen() Function
  2. The memcmp() Function
  3. The memicmp() Function
  4. The strcmp() Function
  5. The stnicmp() Function
  6. The strncmp() Function
  7. The strnicmp() Function
  8. The strspn() Function
  9. The strcspn() Function
  10. The strcoll() Function
  11. The strstr() Function
  12. The memchr() Function
  13. The strchr() Function
  14. The strrchr() Function 
  15. The strpbrk() Function 
  16. The strrev() Function
  17. The memset() Function
  18. The strset() Function 
  19. The strnset() Function
  20. The strlwr() Function
  21. The strupr() Function
  22. The memcpy() Function
  23. The memmove() Function
  24. The strcpy() Function
  25. The strncpy() Function 
  26. The strdup() Function
  27. The strcat() Function
  28. The strncat() Function 
  29. The strtok() Function

C++ Graphics Mode Functions

      In C++ programming language, we can create different objects such as lines, circles, rectangle and many other shapes using various graphics built-in functions. The commonly used graphics functions used to create graphics objects are as follows:
  1. The circle() Function
  2. The arc() Function
  3. The pieslice() Function
  4. The putpixel() Function
  5. The getpixel() Function
  6. The line() Function 
  7. The rectangle() Function 
  8. The setlinestyle() Function
  9. The bar() Function
  10. The har3d() Function
  11. The getimage() Function
  12. The putimage() Function

C++ Graphics Text Mode Functions

      In graphics mode, text can also be displayed in different fonts, styles, sizes, colors and directions. The graphics functions that are commonly used to create and print text are as follows:
  1. The outtext() Function
  2. The moveto() Function
  3. Tlie outtextxy() Function
  4. The settextstyle() Function 
  5. The setcolor() Function
  6. The setbkcolor() Function.