ImageVerifierCode 换一换
格式:DOCX , 页数:17 ,大小:73.18KB ,
资源ID:6630521      下载积分:3 金币
快捷下载
登录下载
邮箱/手机:
温馨提示:
快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。 如填写123,账号就是123,密码也是123。
特别说明:
请自助下载,系统不会自动发送文件的哦; 如果您已付费,想二次下载,请登录后访问:我的下载记录
支付方式: 支付宝    微信支付   
验证码:   换一换

加入VIP,免费下载
 

温馨提示:由于个人手机设置不同,如果发现不能下载,请复制以下地址【https://www.bingdoc.com/d-6630521.html】到电脑端继续下载(重复下载不扣费)。

已注册用户请登录:
账号:
密码:
验证码:   换一换
  忘记密码?
三方登录: 微信登录   QQ登录  

下载须知

1: 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。
2: 试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。
3: 文件的所有权益归上传用户所有。
4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
5. 本站仅提供交流平台,并不能对任何下载内容负责。
6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

版权提示 | 免责声明

本文(机房收费管理系统.docx)为本站会员(b****4)主动上传,冰点文库仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知冰点文库(发送邮件至service@bingdoc.com或直接QQ联系客服),我们立即给予删除!

机房收费管理系统.docx

1、机房收费管理系统 LG GROUP system office room 【LGA16H-LGYY-LGUA8Q8-LGA162】机房收费管理系统第一章 课程设计任务内容 1第二章 详细课程设计 2系统总体模块图 2 系统的功能模块划分 2 主要函数介绍 3 系统程序代码及注释 3第三章 软件使用说明 8 录入系统 8 计算功能 9 查询功能 9 机器使用情况 10第四章 课程设计心得与体会 11附录一:程序清单 12第1章 课程设计任务内容 题目:机房收费管理系统目前,在部分高校中,计算机机房的上机收费仍然采用传统的人工计时方式,即学生凭有效证件前来上机,由机房管理人员手工登记开始时间和结束

2、时间,然后按实际机时进行计算并收取相应费用。人工计时计费方式不但效率低,而且容易出错,也不利于定期的统计工作。随着高校学生人数的不断增加,这些工作的难度和强度也不断加大,给机房管理部门带来了很大的压力。本课程设计要求实现机房收费管理系统,具体任务如下:(1)输入功能:输入30名学生的学号、班级、姓名、上机起始时间。(2)计算功能:计算每个下机学生的上机费用,每小时1元。(上机费用=上机时间* h ,不足一小时按一小时计算)(3)查询功能:按条件(班级、学号、姓名)显示学生的上机时间。(4)机器使用情况的显示(显示方式不限但要一目了然)。第二章 详细课程设计系统总体模块图系统的整体模块描述如图所

3、示图3-1 系统总体模块图 系统的功能模块划分 每一条记录包含一个学生学号、学生班级、学生姓名、上机起始时间,同时包含:完成对学生上机时间的录入;按条件(班级、学号、姓名)显示学生的上机时间,计算每个下机学生的上机费用,并能根据学生的上机时间进行计算上机费用,而且还能显示机器使用情况。 主要函数介绍 Main-menu函数:输出机房管理系统菜单 Input函数:输入若干学生的学号、班级和姓名及上机时间 Online函数:学生上机,输入上机学生学号或姓名及时间Calculator函数:计算上机费用并输出Offline函数:学生下机时间,调用calculator函数得到上机费用Search函数:查

4、找学生上机信息Display函数:显示全部机器的使用信息Main函数:函数调用以及结束程序 系统程序代码及注释输入功能:输入30名学生的学号、班级、姓名、上机起始时间#include#include #include#include#define N 20#define M 100 struct student char idN; char theclassN; char nameN; char ontimeN;studentM;int n;void addition() int i; printf(n请输入录入学生信息的总数:);scanf(%d,&n);for(i=1;i=n;i+) pr

5、intf(nt请输入第%d个学生学号(20s):,i);scanf(%s,studenti-1.id);printf(nt请输入第%d个学生班级(20s):,i);scanf(%s,studenti-1.theclass); printf(nt请输入第%d个学生姓名(20s):,i); scanf(%s,studenti-1.name); printf(nt请输入第%d个学生上机时间(20s)(例:02):,i); scanf(%s,studenti-1.ontime); printf(nt提示:您已成功录入第%d条信息n,i); 计算功能:计算每个下机学生的上机费用,每小时1元。(上机费用=

6、上机时间* h ,不足一小时按一小时计算)void calculate() int hours;char times30; time_t rawtime; struct tm * timeinfo;time ( &rawtime );timeinfo = localtime(&rawtime ); strcpy(times,asctime(timeinfo); printf(t所有学生上机费用如下:n);for(int i=1;i(times14-48)*10+times15) hours=(times11-48)*10+times12-(studenti-1.ontime0-48)*10-s

7、tudenti-1.ontime1;else hours=(times11-48)*10+times12-(studenti-1.ontime0-48)*10-studenti-1.ontime1+1; printf(%dn,hours); void calculate() int hours;char times30; time_t rawtime; struct tm * timeinfo;time ( &rawtime );timeinfo = localtime(&rawtime ); strcpy(times,asctime(timeinfo); printf(t所有学生上机费用如下

8、:n);for(int i=1;i(times14-48)*10+times15) hours=(times11-48)*10+times12-(studenti-1.ontime0-48)*10-studenti-1.ontime1;else hours=(times11-48)*10+times12-(studenti-1.ontime0-48)*10-studenti-1.ontime1+1; printf(%dn,hours); 查询功能:按条件(班级、学号、姓名)显示学生的上机时间。void search() int i,b,c,count; do char find20; prin

9、tf(n请选择查询方式:1.根据学号查询;2.根据班级查询;3.根据姓名查询;4.根据上机时间:);scanf(%d,&b);switch(b) case 1: count=PF_FLOATING_POINT_PRECISION_ERRATA; printf(n*请输入学生的学号:);scanf(%s,find);for(i=0;in;i+) if (strcmp(studenti.id,find)=0) count+; if(count=PF_FLOATING_POINT_EMULATED)printf(学生学号t学生班级t学生姓名t上机时间n); printf(%8s%15s%15s%17

10、s,studenti.id,studenti.theclass, studenti.name,studenti.ontime); if(!count)printf(*提示:该生不存在);goto A; case 2: count=PF_FLOATING_POINT_PRECISION_ERRATA;printf(n*请输入学生的班级:); scanf(%s,find);for(i=0;in;i+) if (strcmp(studenti.theclass,find)=0) count+;if(count=PF_FLOATING_POINT_EMULATED) printf(学生学号t学生班级t

11、学生姓名t上机时间n); printf(%8s%15s%15s%17s,studenti.id,studenti.theclass, studenti.name,studenti.ontime); if(!count)printf(*提示:该生不存在);goto A;case 3: count=PF_FLOATING_POINT_PRECISION_ERRATA;printf(n*请输入学生的姓名:);scanf(%s,find); for(i=0;in;i+) if (strcmp(studenti.name,find)=0) count+; if(count=PF_FLOATING_POI

12、NT_EMULATED) printf(学生学号t学生班级t学生姓名t上机时间n); printf(%8s%15s%15s%17s,studenti.id,studenti.theclass, studenti.name,studenti.ontime); if(!count) printf(*提示:该生不存在);goto A; case 4: count=PF_FLOATING_POINT_PRECISION_ERRATA; printf(n*请输入学生的上机时间:);scanf(%s,find);for(i=0;in;i+) if (strcmp(studenti.ontime,find)

13、=0) count+; if(count=PF_FLOATING_POINT_EMULATED)printf(学生学号t学生班级t学生姓名t上机时间n); printf(%8s%15s%15s%17s,studenti.id,studenti.theclass, studenti.name,studenti.ontime); if(!count)printf(*提示:该生不存在);goto A;default:printf(*提示:输入错误); A:printf(nt*1.继续nt*0.返回主菜单); printf(nt 请输入您的选择:);scanf(%d,&c);while(c);机器使用

14、情况的显示(显示方式不限但要一目了然)void menu() printf(nt*欢迎进入机房收费管理系统!*n);printf(t* 1.录入功能2.计算功能*n);printf(t* 3.查询功能*EXIT*- *n); printf(t*n);printf(nt 请输入您的选择:);void main() system(color 5f);int a;C:menu();scanf(%d,&a);switch(a) case 0:printf(*正在退出*谢谢使用本系统,再见);break;case 1:addition();goto C; /*录入功能*/ case 2:calculat

15、e();goto C; /*浏览功能*/ case 3:search();goto C; /*查询功能*/ 第三章 软件使用说明 录入系统图3-1 输入30名学生的学号、班级、姓名、上机起始时间 计算功能图3-2计算每个下机学生的上机费用 查询功能图3-3 按条件(班级、学号、姓名)显示学生的上机时间 机器使用情况图3-4 机器使用情况查询第四章 课程设计心得与体会 在这次课程设计中,我体会颇多,学到很多东西。我加强了对C+的认识,复习了自己以前的知识,自己的逻辑思考能力也提高不少。从而对Microsoft Visual C+ 又有了更深入的认识!在这次课程设计中,我还懂得了程序开发的一些比较

16、重要的步骤,比如需求分析、总体设计、程序模块设计(含功能需求、程序代码设计与分析、运行结果)、系统使用说明等。总之,通过这次课程设计,我收获颇丰,相信会为自己以后的学习和工作带来很大的好处。最重要的还是激发了我编程的兴趣和热情,让我从一个只懂理论变成了能做一些小型程序,让我对编程更加热爱了。整体地评价这次课程设计,我认为收获很大,正如上面所说的那样,通过课程设计,既复习了以前的旧知识,又学到了一些新的知识;设计增强了我们用所学知识去解决具体问题的能力,进一步培养了我们独立思考问题和解决问题的能力。特别是学会了在Visual C+ 集成开发环境中如何调试程序的方法。当然,老师的悉心指导和同学的帮

17、助也是不可忽视的,在此感谢本次课程设计中辅导老师对我的关心和帮助,诚心诚意感谢她对我的鼓励与教导,是她在我迷茫的时候给了我些许提示,激发了我编程的灵感;还有,我在此也十分感谢本次课程设计中同学们对我的帮助,尽管本次不是团队合作,但是他们也给了我不少的提示和帮助,是他们让我有信心坚持做下来,在此感谢他们!附录一:程序清单#include#include #include#include#define N 20#define M 100 struct student char idN; char theclassN; char nameN; char ontimeN; studentM; int

18、n; void addition() int i; printf(n请输入录入学生信息的总数:); scanf(%d,&n); for(i=1;i=n;i+) printf(nt请输入第%d个学生学号(20s):,i); scanf(%s,studenti-1.id); printf(nt请输入第%d个学生班级(20s):,i); scanf(%s,studenti-1.theclass); printf(nt请输入第%d个学生姓名(20s):,i); scanf(%s,studenti-1.name); printf(nt请输入第%d个学生上机时间(20s)(例:02):,i); scanf

19、(%s,studenti-1.ontime); printf(nt提示:您已成功录入第%d条信息n,i); (上机费用=上机时间* h ,不足一小时按一小时计算)void calculate() int hours; char times30; time_t rawtime; struct tm * timeinfo; time ( &rawtime ); timeinfo = localtime(&rawtime ); strcpy(times,asctime(timeinfo); printf(t所有学生上机费用如下:n); for(int i=1;i(times14-48)*10+tim

20、es15) hours=(times11-48)*10+times12-(studenti-1.ontime0-48)*10-studenti-1.ontime1; else hours=(times11-48)*10+times12-(studenti-1.ontime0-48)*10-studenti-1.ontime1+1; printf(%dn,hours); void calculate() int hours; char times30; time_t rawtime; struct tm * timeinfo; time ( &rawtime ); timeinfo = loca

21、ltime(&rawtime ); strcpy(times,asctime(timeinfo); printf(t所有学生上机费用如下:n); for(int i=1;i(times14-48)*10+times15) hours=(times11-48)*10+times12-(studenti-1.ontime0-48)*10-studenti-1.ontime1; else hours=(times11-48)*10+times12-(studenti-1.ontime0-48)*10-studenti-1.ontime1+1; printf(%dn,hours); void sear

22、ch() int i,b,c,count; do char find20; printf(n请选择查询方式:1.根据学号查询;2.根据班级查询;3.根据姓名查询;4.根据上机时间:); scanf(%d,&b); switch(b) case 1: count=PF_FLOATING_POINT_PRECISION_ERRATA; printf(n*请输入学生的学号:); scanf(%s,find); for(i=0;in;i+) if (strcmp(studenti.id,find)=0) count+; if(count=PF_FLOATING_POINT_EMULATED) prin

23、tf(学生学号t学生班级t学生姓名t上机时间n); printf(%8s%15s%15s%17s,studenti.id,studenti.theclass, studenti.name,studenti.ontime); if(!count) printf(*提示:该生不存在); goto A; case 2: count=PF_FLOATING_POINT_PRECISION_ERRATA; printf(n*请输入学生的班级:); scanf(%s,find); for(i=0;in;i+) if (strcmp(studenti.theclass,find)=0) count+; if

24、(count=PF_FLOATING_POINT_EMULATED) printf(学生学号t学生班级t学生姓名t上机时间n); printf(%8s%15s%15s%17s,studenti.id,studenti.theclass, studenti.name,studenti.ontime); if(!count) printf(*提示:该生不存在); goto A; case 3: count=PF_FLOATING_POINT_PRECISION_ERRATA; printf(n*请输入学生的姓名:); scanf(%s,find); for(i=0;in;i+) if (strcm

25、p(studenti.name,find)=0) count+; if(count=PF_FLOATING_POINT_EMULATED) printf(学生学号t学生班级t学生姓名t上机时间n); printf(%8s%15s%15s%17s,studenti.id,studenti.theclass, studenti.name,studenti.ontime); if(!count) printf(*提示:该生不存在); goto A; case 4: count=PF_FLOATING_POINT_PRECISION_ERRATA; printf(n*请输入学生的上机时间:); sca

26、nf(%s,find); for(i=0;in;i+) if (strcmp(studenti.ontime,find)=0) count+; if(count=PF_FLOATING_POINT_EMULATED) printf(学生学号t学生班级t学生姓名t上机时间n); printf(%8s%15s%15s%17s,studenti.id,studenti.theclass, studenti.name,studenti.ontime); if(!count) printf(*提示:该生不存在); goto A; default:printf(*提示:输入错误); A:printf(nt*1.继续nt*0.返回主菜单); printf(nt 请输入您的选择:); scanf(%d,&c); while(c); void menu() printf(nt*欢迎进入机房收费管理系统!*n); printf(t* 1.录入功能2.计算功能*n); printf(t* 3.查询功能*EXIT*- *n); printf(t*n); printf(nt 请输入您的选择

copyright@ 2008-2023 冰点文库 网站版权所有

经营许可证编号:鄂ICP备19020893号-2