C Header files and Reserved Keywords in C++ - What is Keywords in C/C++ - C Header files and Reserved Keywords of C++ Definition and Examples by LearningZone24...
Header files and Reserved words in C++
Header files:
C Header files are standard library files that have an extension of <.h> and which are used to hold declarations for other data.
Consider the following program:
//C Header files example
#include <iostream.h>
int main( )
{
cout <<"Hello, world!" <<endl:
return 0;
}
Output of the program
Hello, world!
This program prints the string "Hello, world!" to the screen using cout. However, this program never defines cout, so how does the compiler know about the object cout? The answer to this is that cout has been declared in a header file called "iostream". When the line #include <iostream> is used in the program, the compiler locates and read all the declarations room a C Header files named "iostream"
Reserved words:
Reserved words are keywords are those words which have their special meaning within the C++ language and are reserved for some specific purpose. C++ reserved words can not be used for any other object in C++ language and even cannot be used as variables.