All the class definitions (class whatever { } need to go into a header, and the code for the functions in those classes need to go into a .cpp file.

Well, you can write small functions inline inside the header and they'll get expanded for extra performance (but big functions won't, so it's best to put those in source files).