#include"student.h"
#include"student2.h"
#include"student3.h"
#include"student4.h"
#include"student5.h"
int main()
{
// the first student
STUDENT A = Createstudent("AA BB CC");
printf("student1:%s\n", GetNameFromStudent(A));
// the second student
printf("\n");
STUDENT2 B = Createstudent2("DD EE");
printf("student2:%s\n", GetNameFromStudent2(B));
// the third student
printf("\n");
STUDENT3 C = Createstudent3("FF GG");
printf("student3:%s\n", GetNameFromStudent3(C));
// the fourth student
printf("\n");
STUDENT4 D = Createstudent4("HH II JJ");
printf("student4:%s\n", GetNameFromStudent4(D));
// the fifth student
printf("\n");
STUDENT5 E = Createstudent5("KK LL", 123456789);
printf("student5:%s\n", GetNameFromStudent5(E));
printstudent5(E);
return 0;
}
:(
错误提示是啥?找不到这5个头文件还是头文件有错误?还是这5个头文件没有对应的cpp文件?
你能不能尝试下仅引用第一个student,然后实例化时什么2345都去掉,实例化student就行