Hi,

you should read C++ more carefully, those things that you mixed them with each other are different things. I hope that i can clear some concepts for you.
-- first, using header files and cpp file:

as you should know, we can write all program codes in a single file and then compile it, but it's not a good idea, but we can write them in separate files according to their coherence.

in a common solution, we can write declaration of each class in a .h file and its implementation in a . cpp file and every where we need each class #include its header file.

with the help of #def, #ifndef macros we can prevent multiple inclusion of header files.
e.g. for myheader.h file:
Qt Code:
  1. #ifndef __MYHEADER_H_
  2. #def __MYHEADER_FILE_H_
  3.  
  4. //here we write header codes
  5. #endif
To copy to clipboard, switch view to plain text mode 

-- second, inline functions don't relate to where they are implemented! you can use them before every small function to prevent unnecessary function calls.
Qt Code:
  1. inline int max(int a, int b){
  2. return (a<b)?b:a;
  3. }
To copy to clipboard, switch view to plain text mode 

--third, static member functions, are functions that can be used with class name, and need not an instance of an object of that class. and const member functions are usefull when you have a const instance of an object. so it's not necessary that define const static functions.