您好我对结构数组有点困惑......
如何使用此结构创建数组:
struct m_StudentData
{
char Sex, Class [10];
char Phone [15];
char Name, Surname, Nationality [30];
char Rooms, Subjects, Mail [64];
CString Information, Address;
CDateTimeCtrl Birthday;
}
答案 0 :(得分:2)
简单,只需将结构用作类型
struct m_StudentData
{
char Sex, Class [10];
char Phone [15];
char Name, Surname, Nationality [30];
char Rooms, Subjects, Mail [64];
CString Information, Address;
CDateTimeCtrl Birthday;
};
m_StudentData arr[30];