A word on the header (.h) files
Header files are supposed to contain definitions only, and not actual code. If you include code in a header file, this will usually lead to linker errors. Header files will be included in many places. Never put any actual code in header files.
Definitions must be made only once per compiler run; so always prevent a header file from being included more than once with a preprocessor construct:
The statements will only be “seen” if the “__PI_H_” is not defined, that means, if we include the file again, we will be ok.
We have functions in emacs which automatically generate the “ifndef… define … endif” enclosure for header files.