- 2
- 0
- 约1.3万字
- 约 80页
- 2018-04-13 发布于河南
- 举报
第七章结构体、共用体和枚举类型数据余
#include “stdio.h” #include “alloc.h” struct student { char name[20]; int age; struct student *next; }; struct student *head,*new,*this; main() { void new_one(void); void out_put(void); char c; int flag=1; new=(struct student*)malloc(sizeof(struct student)); gets(new-name); scanf(“%d”,new-age);getchar(); new-next=NULL; head=new; while(flag) { printf(“New student to add in?(Y/N)”); c=getchar();getchar(); if(c==’y’||c==’Y’) new_one(); else {out_put();flag=0;} } } void new_one(void) { new=(struct student*)malloc(sizeof(struct student)); ge
您可能关注的文档
最近下载
- 乙烯基甲苯(混合异构体)-国际化学品安全卡.pdf VIP
- DB31_T 1660-2025 数据中心基础设施建设指南.pdf VIP
- DB1301T 428-2022 富硒黄冠梨绿色生产技术规程.docx VIP
- 2025年固态电池产业链研究报告-深企投.pdf
- 大跨度连续梁刚构桥常见病害分析及处治对策.pptx VIP
- (高清版)DB5110∕T 32-2021 内江黑猪商品猪生产技术规程. .pdf VIP
- DB15∕T 4281-2026 湖泊环境微塑料监测技术指南.pdf VIP
- DB1302T 533-2021 农业社会化服务 病虫害防控服务规范.docx VIP
- 2016年中小学幼儿园教师职称考试物理试题.pdf VIP
- DB21_T 4173-2025 城市地下综合管廊工程技术规程.docx VIP
原创力文档

文档评论(0)