跪求各位 c语言程序设计 学生成绩管理系统

来源:百度知道 编辑:UC知道 时间:2024/06/17 22:57:57
1)能按学期、按班级完成对学生成绩的录入、修改
(2)能按班级统计学生的成绩,求学生的总分及平均分,并能根据学生的平均成绩进行排序
(3)能查询学生成绩,不及格科目及学生名单
(4)能按班级输出学生的成绩单
我的邮箱是 qiaoyuanhao001@163.com
不要粘贴的 运行不了 谢谢各位了
答得好我能给加钱

#include<stdio.h>
#include<string.h>
#include<malloc.h>
#define LEN sizeof(struct stu)
//#define NULL 0
struct score
{
char work1[64];
int score1;
char work2[64];
int score2;
char work3[64];
int score3;
};
struct stu
{
char name[100];
int age;
int classes;
char address[500];
char telephone[14];
struct score results;
struct stu *next;
};
struct stu *create(void)//创建链表
{
struct stu *p1,*p2,*head;
int n=0;
p1=p2=(struct stu *)malloc(LEN);
head=NULL;
printf("input the name: \nif name is empty,stop.\n");
while(1)
{
gets(p1->name);
if(p1->name[0]=='\0')
{
p2->next=NULL;
free(p1);
break;
}
else
{
printf("input : ");
scanf("%d",&p1->age);getchar();