additional cpp files

Really n00b question...
I've seen programs with more than one cpp file. I use lots of h files, but never cpp files. What's the difference? Also, even more confusing, I see no reference given to the additional cpp files from the main cpp file, unlike h files.

Thanks!
Last edited on
Headers aren't compiled. You can use extra source files to separate the program into logical sections (for example, a text editor could have the code that outputs to the screen in one file, and the code that takes user input in another), or to split it when it becomes too large, as there's nothing more annoying than navigating a text file thousands of lines long.
http://www.cplusplus.com/forum/unices/2313/page1.html#msg8761
I had another post that was better, but I can't find it now...
Topic archived. No new replies allowed.