依照下面定义,能打印出字母M语句是( D )。struct person{char name[9];int age;};struct person class[10]={"John",17,"Paul",19,"Mary",18,"adam",16};

依照下面定义,能打印出字母M语句是( D )。struct person{char name[9];int age;};struct person class[10]={"John",17,"Paul",19,"Mary",18,"adam",16};

A、printf("%c\n",class[3].name);

B、printf("%c\n",class[3].name[1]);

C、printf("%c\n",class[2].name[1]);

D、printf("%c\n",class[2].name[0]);

本站整理有大量高等教育、资格考试类试题答案,Ctrl+D收藏备用!

答案解析