The preprocessor is able to add and
remove code from your source file using the #include
directive. This is an instruction that tells the preprocessor to include
code from a particular file. As an example, consider the HelloWorld
program which uses the following directive:-
#include <iostream.h>
This tells the preprocessor to include
code from the file iostream.h (Input-Output-Stream).
This file contains declarations for functions that the program needs
to use, such as the cout function.
The cout function helps you
to write to the screen.
The effect of the directive is as
if you had typed in the code inside iostream.h into your
own file. In other words the #include
directive says, "What follows is a filename; find that file and
read it in right here."
Of course, the preprocessor has to
find the file first. This is what the angle brackets around the filename
are for. They tell the preprocessor to look in the usual folder that
holds all the .H files for your compiler.
Normally this will be the C:\Program Files\Microsoft Visual Studio\VC98\Include
folder.