next==NULL){" /> next==NULL){" />

全文预览

数据结构课程设计-实现十进制数N和二进制数之间的转换-学生成绩管理-拓扑排序

上传者:梦&殇 |  格式:doc  |  页数:27 |  大小:0KB

文档介绍
*****\n");scanf("%d",&num);switch(num){case1:StuInputHand(head);break;case2:StuInputFile(head);default:decide='n';break;}}}voidStuInputHand(Student*head)//学生成绩管理系统的手动输入函数,由输入函数调用{if(head->next==NULL){Student*point=(Student*)malloc(sizeof(Student));//链表中最后一个节点,只在该函数中存在point->next=NULL;intdecide=1;while(decide!=0){Student*p=(Student*)malloc(sizeof(Student));p->next=NULL;StuImport(head,p);if(head->next==NULL){head->next=p;point=p;}else{point->next=p;point=p;}printf("是否继续:1/0\n");scanf("%d",&decide);}}elseprintf("管理系统中已存在信息,若想输入学生信息,请转插入子系统");}voidStuInputFile(Student*head)//学生成绩管理系统的文件输入函数,由输入函数调用{if(head->next!=NULL){printf("学生管理系统中已有信息,请跳转到插入选项\n");}FILE*fp;printf("请输入文件名(包括物理地址)\n");charfilename[10];scanf("%s",filename);if((fp=fopen(filename,"r"))==NULL){printf("cannotopenfile\n");return;}

收藏

分享

举报
下载此文档