当前位置: 首页 > news >正文

简述网站的建设方案宁波网页开发哪家好

简述网站的建设方案,宁波网页开发哪家好,建设银行征信中心官方网站,网站域名去哪买链表A#xff0c;每个节点存放一个新的链表B1#xff0c;B2,B3,B4,B5的头结点。 场景#xff1a;一个年级#xff0c;相当链表A 该年级5个班#xff0c;每个班5个人#xff0c;相当于链表B1–B5 做一个学生成绩管理系统 学生成绩有语文 数学 英语 功能#xff1a; 录入成…链表A每个节点存放一个新的链表B1B2,B3,B4,B5的头结点。 场景一个年级相当链表A 该年级5个班每个班5个人相当于链表B1–B5 做一个学生成绩管理系统 学生成绩有语文 数学 英语 功能 录入成绩 找最三科总分的最高分 最低分 算出平均分 #includestdio.h #includestdlib.h #includestring.h struct people {char* name;int lesson;int number;int math;int chinese;int english;int all;struct people* next; };struct class {int class;struct people* firstpeople;struct class* next; };struct class* insertfromclassbehind(struct class* classhead,struct class* classnewnode) {struct class* pNULL;pclasshead;if(classheadNULL){classheadclassnewnode;return classhead;}struct people* insertfrompeoplebefore(struct people* peoplehead,struct people* peoplenewnode) {if(peopleheadNULL){peopleheadpeoplenewnode;}else{peoplenewnode-nextpeoplehead;peopleheadpeoplenewnode;}return peoplehead; }void linkPrintf(struct class* head) {struct people* pNULL;if(headNULL){printf(打印失败链表为空\n);}while(head!NULL){phead-firstpeople;while(p!NULL){printf(姓名:%s\n,p-name);printf(班级:%d\n,p-lesson);printf(学号:%d\n,p-number);printf(数学:%d\n,p-math);printf(语文:%d\n,p-chinese);printf(英语:%d\n,p-english);printf(---------------------------------------------------------------------------------------------------\n);pp-next;}headhead-next;} }struct class* creatnewlink(struct class* classhead,struct people* peoplehead,int classall) {struct class* classnewnodeNULL;struct people* peoplenewnodeNULL;while(classall){int number;classnewnode(struct class*)malloc(sizeof(struct class));classnewnode-nextNULL;classnewnode-firstpeopleNULL;printf(请输入班级:\n);scanf(%d,classnewnode-class);printf(请输入该班的人数:\n);scanf(%d,number);while(number){peoplenewnode(struct people*)malloc(sizeof(struct people));peoplenewnode-nextNULL;peoplenewnode-name(char*)malloc(128);memset(peoplenewnode-name,\0,128);peoplenewnode-lessonclassnewnode-class;printf(请输入姓名:\n);scanf(%s,peoplenewnode-name); // printf(输入的是:%s\n,peoplenewnode-name);printf(请输入学号:\n);scanf(%d,peoplenewnode-number);printf(请输入数学成绩:\n);scanf(%d,peoplenewnode-math);printf(请输入语文成绩:\n);scanf(%d,peoplenewnode-chinese);printf(请输入英语成绩:\n);scanf(%d,peoplenewnode-english);peoplenewnode-allpeoplenewnode-englishpeoplenewnode-mathpeoplenewnode-chinese;peopleheadinsertfrompeoplebefore(peoplehead,peoplenewnode);number--;}classnewnode-firstpeoplepeoplehead;peopleheadNULL;//printf(****************************);classheadinsertfromclassbehind(classhead,classnewnode);classall--;}return classhead; }void findmaxall(struct class*head) {struct class* phead;struct people* p2p-firstpeople;struct people* maxNULL;maxp2;if(pNULL){printf(参数不能为空!\n);}while(p!NULL){p2p-firstpeople;while(p2!NULL){if(max-allp2-all){maxp2;}p2p2-next;}pp-next;}printf(---------------------------------------------------------------------------------------------------\n);printf(总分最高为:%d,姓名:%s,班级:%d,学号:%d\n,max-all,max-name,max-lesson,max-number);printf(---------------------------------------------------------------------------------------------------\n); }void findminall(struct class*head) {struct class* phead;struct people* p2p-firstpeople;struct people* minNULL;minp2;if(pNULL){printf(参数不能为空!\n);}while(p!NULL){p2p-firstpeople;while(p2!NULL){if(min-allp2-all){minp2;}p2p2-next;}pp-next;}printf(总分最低为:%d,姓名:%s,班级:%d,学号:%d\n,min-all,min-name,min-lesson,min-number);printf(---------------------------------------------------------------------------------------------------\n); }void findaverage(struct class* head) {int mathall,chineseall,englishall,peopleall;mathallchineseallenglishallpeopleall0;struct people* p;if(headNULL){printf(链表为空错误\n);}while(head!NULL){phead-firstpeople;while(p!NULL){mathallp-mathmathall;chineseallp-chinesechineseall;englishallp-englishenglishall;peopleall;pp-next;}headhead-next;}//printf(语文:%d,数学:%d,英语:%d\n,chineseall,mathall,englishall);printf(语文平均分:%f\n,(float)chineseall/peopleall);printf(数学平均分:%f\n,(float)mathall/peopleall);printf(英语平均分:%f\n,(float)englishall/peopleall);printf(---------------------------------------------------------------------------------------------------\n); } int main() {struct class* classheadNULL;struct people* peopleheadNULL;int classall;printf(请输入班级总数:\n);scanf(%d,classall);classheadcreatnewlink(classhead,peoplehead,classall);findmaxall(classhead);findminall(classhead);findaverage(classhead);//linkPrintf(classhead);return 0; }
http://www.sadfv.cn/news/38061/

相关文章:

  • 国内外免费域名解析网站牡丹江市建设工程交易中心网站
  • 可以做app的网站做电影网站用的云盘
  • 邵阳建网站多少钱东莞企业网站建立报价
  • 电商设计网站素材能赚钱的网站
  • 厦门网站搜索优化做网站后台的时候要注意什么
  • 58同城网站建设要多少钱wordpress 待审文章
  • dota2海涛做的网站科技为了上大学上交可控核聚变免费阅读
  • 网站建设方案 下载郑州房产网新房
  • 杭州网站建设怎么样软件开发文档用什么写
  • 做网站优化为什么要用国外服务器做网站
  • 北京工商局网站怎么做增资福清网站建设专家
  • 做网站挂谷歌广告赚钱吗找一个网站做搜索引擎分析
  • 实现微信绑定登录网站软文怎么优化网站
  • 网站建设可实施性报告微信营销方式
  • 二进制可以做网站是吗网站备案登录
  • asp网站如何打开网站怎么样被百度收录
  • 电脑手机网站首页员工信息查询系统
  • 格朗图手表网站怎么给网站做缓存
  • 如何管理企业网站企业网站首页图片
  • 社保网站做员工用工备案一个网站3个相似域名
  • 中国行业网站大全如何为企业网站设计完整的推广方案
  • 建站如何收费河北建设工程信息网联系电话
  • 广州企业网站建设上海公司牌照价格
  • 秀洲区住房和城乡建设局网站布吉网站建设哪家技术好
  • 沈阳建设厅网站首页创新的企业网站制作
  • 网站建设相关论文电子商务工资多少钱一个月
  • 如何查询网站点击率网站更新维护页面
  • 如何高效建设品牌网站wordpress微信机器人破解版
  • 网站别人帮做的要注意什么东西扁平网站设计
  • 怎么查看网站dns网页设计素材背景图片