学生成绩管理系统V

上传人:M****1 文档编号:568427559 上传时间:2024-07-24 格式:PDF 页数:5 大小:80.77KB
返回 下载 相关 举报
学生成绩管理系统V_第1页
第1页 / 共5页
学生成绩管理系统V_第2页
第2页 / 共5页
学生成绩管理系统V_第3页
第3页 / 共5页
学生成绩管理系统V_第4页
第4页 / 共5页
学生成绩管理系统V_第5页
第5页 / 共5页
亲,该文档总共5页,全部预览完了,如果喜欢就下载吧!
资源描述

《学生成绩管理系统V》由会员分享,可在线阅读,更多相关《学生成绩管理系统V(5页珍藏版)》请在金锄头文库上搜索。

1、.#include #include #include int main()int a,b,d,e,n,z;float c=0,g;printf(Input student number(n30):n);scanf(%d,&n);long vn,f;float vcn;next:;int x1=0,x2=0,x3=0,x4=0,x5=0,x6=0;int z1=60,z2=69,z3=70,z4=79,z5=80,z6=89,z7=90,z8=99,z9=100;printf(Management for Students scoresn1.Input recordn2.Caculate to

2、tal and average score of coursen3.Sort in descending order by scoren4.Sort in ascending order by scoren5.Sort in ascending order by numbern6.Search by numbern7.Statistic analysisn8.List recordn0.ExitnPlease Input your choice:n);scanf(%d,&a);switch (a)case 1:printf(Input students ID and score:n);for

3、(b=0;bn;b+)scanf(%ld%f,&vb,&vcb);break;case 2:for (b=0;bn;b+)c=c+vcb;printf(sum=%.0f,aver=%.2fn,c,c/n);break;.word.zl.case 3:printf(Sort in descending order by score:n);for (d=0;dn;d+)for (e=d+1;en;e+)if (vcdvce)g=vcd;vcd=vce;vce=g;g=vd;vd=ve;ve=g;for (b=0;bn;b+)printf(%ldt%.0fn,vb,vcb);break;case 4

4、:printf(Sort in ascending order by score:n);for (d=0;dn;d+)for (e=d+1;evce)g=vcd;vcd=vce;vce=g;g=vd;vd=ve;ve=g;for (b=0;bn;b+)printf(%ldt%.0fn,vb,vcb);break;.word.zl.case 5:printf(Sort in ascending order by number:n);for (d=0;dn;d+)for (e=d+1;eve)g=vcd;vcd=vce;vce=g;g=vd;vd=ve;ve=g;for (b=0;bn;b+)pr

5、intf(%ldt%.0fn,vb,vcb);break;case 6:printf(Input the number you want to search:n);scanf(%ld,&f);z=0;for (b=0;bn;b+)if (vb=f)printf(%ldt%.0fn,vb,vcb);z=1;break;if (z=0)printf(Not found!n);break;case 7:for (b=0;bn;b+)if (vcb60).word.zl.x1+;else if (vcb70)x2+;else if (vcb80)x3+;else if (vcb90)x4+;else

6、if (vcb100)x5+;elsex6+;printf(60t%dt%.2f%n,x1,(float)x1/n*100);printf(%d-%dt%dt%.2f%n,z1,z2,x2,(float)x2/n*100);printf(%d-%dt%dt%.2f%n,z3,z4,x3,(float)x3/n*100);printf(%d-%dt%dt%.2f%n,z5,z6,x4,(float)x4/n*100);printf(%d-%dt%dt%.2f%n,z7,z8,x5,(float)x5/n*100);printf(%dt%dt%.2f%n,z9,x6,(float)x6/n*100);break;case 8:for (d=0;dn;d+)for (e=d+1;eve)g=vcd;vcd=vce;vce=g;g=vd;vd=ve;ve=g;for (b=0;bn;b+)printf(%ldt%.0fn,vb,vcb);break;case 0:printf(End of program!n);goto end;default:.word.zl.printf(Input error!n);goto next;end:;.word.zl.

展开阅读全文
相关资源
正为您匹配相似的精品文档
相关搜索

最新文档


当前位置:首页 > 建筑/环境 > 施工组织

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号