Помагите исправить ошибку в программе C++
Задание
Создать иерархию типов, описывающую - человека, студента, отца семейства и студента-отца семейства. Использовать виртуальные базовые классы.
Код программы
#include "stdafx.h"
#include "iostream"
#include
using namespace std;
class human
{
string name;
public:
human(string humname ): name(humname) {}
string getName()
{
return name;
}
};
class student: virtual public human
{
int curs;
public:
student (string humname, int cnumb ): human(humname), curs(cnumb) {}
int getCurs()
{
return curs;
}
};
class father: virtual public human
{ int childnumb;
public:
father(string humname, int chnum ): human(humname), childnumb(chnum) {}
int getChildnumb()
{
return childnumb;
}
};
class FatherStudent: public student, public father
{
public:
FatherStudent( string humn, int curnum, int chnum): father(humn, chnum), student(humn, curnum) {}
};
int main()
{
FatherStudent ft("Q", 20, 30);
cout << ft.getName();
return 0;