Advertisement
Guest User

Two class include each other

a guest
Oct 25th, 2014
217
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.28 KB | None | 0 0
  1. //Student.h
  2. #include "Courses.h"
  3. #include <vector>
  4. class Student
  5. {
  6. private:
  7.     ...
  8.     vector<Course*> Have_Enrol;
  9. };
  10.  
  11.  
  12. // Course.h
  13. #include <vector>
  14. class Student;
  15. class Course
  16. {
  17. private:
  18.     ...
  19.     vector<Student*> S;
  20. public:
  21.     ...
  22.     void addStudent(Student* StuBeAdded);
  23. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement