Declaration of a class
In C++, seperated .h and .cpp files are used to define one class.
Class declaration and prototypes in that class are in the header file(.h).
All the bodies of these functions are in the sourse file(.cpp).
The header files
If a function is declared in a header file, you must include the header file everywhere the function is used and where the function is defined.
If a class is declared in a header file, you must include the header file everywhere the class is used and where class member functions are defined.
Header=interface
The header is a contract between you and the user of your code.
The compile enforces the contract by requiring you to declare all structures and functions before they are used.
Structure of C++ pro