结构体数组例题二
输出M
struct person
{
char name[9];
int age;
};
struct person class[4]={{"Wang",17},{"Zhang",19},{"Ming",18},{"Liu",20}};
cout<<class[2].name[0];
输出M
struct person
{
char name[9];
int age;
};
struct person class[4]={{"Wang",17},{"Zhang",19},{"Ming",18},{"Liu",20}};
cout<<class[2].name[0];
本文标题:结构体数组例题2
本文链接:https://www.haomeiwen.com/subject/wotmnftx.html
网友评论