资源描述:
《学生成绩管理系统v3.0》由会员上传分享,免费在线阅读,更多相关内容在工程资料-天天文库。
1、//成绩管理系统v3.0//能动1302王清栋1306030217#include#include#include#defineN30voidInput(longnum[],intscore[],intn,charname[][10]);voidTotalave(intscore[],intn);voidScoredes(longnum[],intscore[],intn,charname[][10]);voidScoreas(longnum[],intscore[],intn,cha
2、rname[][10]);voidNumas(longnum[],intscore[],intn,charname[][10]);voidNameorder(longnum[],intscore[],intn,charname[][10]);voidSearchbyno(longnum[],intscore[],intn,intx,charname[][10]);voidSearchbyname(longnum[],intscore[],intn,charc[],charname[][10]);voidstatistis(intscore[]
3、,intn);voidList(longnum[],intscore[],intn,charname[][10]);intmain(){intn,score[N],c,x;longnum[N];charname[N][10];chary[10];printf("输入学生人数");scanf("%d",&n);//getchar();printf("1.Inputrecord");printf("2.Caculatetotelandaveragescoreofeverycourse");printf("3.Sortindescendin
4、gorderbyscore");printf("4.Sortinascendingorderbyscore");printf("5.Sortinascendingorderbynumber");printf("6.Sortindictionaryorderbyname");printf("7.Searchbynumber");printf("8.searchbyname");printf("9.Statisticanalysis");printf("10.Listrecord");printf("0.Exit
5、n");printf("Pleaseenteryourchoice:");printf("");for(;;){scanf("%d",&c);switch(c){case1://录入学生学号和各科成绩Input(num,score,n,name);printf("Pleaseenteryourchoice:");break;case2://计算每门课程的总分和平均分Totalave(score,n);printf("Pleaseenteryourchoice:");break;case3://按chengji由高到低排出名次表
6、Scoredes(num,score,n,name);printf("Pleaseenteryourchoice:");break;case4://按chengji由低到高排出名次表Scoreas(num,score,n,name);printf("Pleaseenteryourchoice:");break;case5://按学号由小到大排出名次表Numas(num,score,n,name);printf("Pleaseenteryourchoice:");break;case6://按学号由小到大排出名次表Nameorder
7、(num,score,n,name);printf("Pleaseenteryourchoice:");break;case7://按学号查询学生排名及其各科成绩printf("请输入查找学号");scanf("%d",&x);Searchbyno(num,score,n,x,name);printf("Pleaseenteryourchoice:");break;case8://按姓名查询学生排名及其各科成绩printf("请输入查找姓名");getchar();gets(y);Searchbyname(num,score,
8、n,y,name);break;printf("Pleaseenteryourchoice:");case9://成绩分析所占百分比statistis(scor