正在加载图片...
9.1结枸定义和使用 ◇结构类型 ◆用户自定义的数据类型 struct是C语言关键字 student是用户定义的标识 符,作为结构的名字,必须 struct student 和 struct联合使用。 int num 体*学号*/ char name 10] /*姓名*/ nt computer, eng l i sh,math;/*成绩*/ doub le average /*平均成绩* };/*不要遗漏分号*/ 结构类型  用户自定义的数据类型 struct student { int num; /*学号*/ char name[10] /*姓名*/ int computer, english, math; /*成绩*/ double average; /*平均成绩*/ };/* 不要遗漏分号 */ struct是C语言关键字 student是用户定义的标识 符,作为结构的名字,必须 和struct联合使用
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有