没有合适的资源?快使用搜索试试~ 我知道了~
学生信息管理系统源代码.txt
需积分: 47 2 下载量 197 浏览量
2020-07-24
13:10:30
上传
评论 1
收藏 20KB TXT 举报
温馨提示
试读
24页
学生成绩管理系统是一个具有整合学生成绩的综合性系统,其功能包括对每个学生成绩的录入、修改、删除、查询等具体功能。学生成绩管理系统运用了结构体、链表、文件等的基本知识,并对各个模块的功能进行整合。作为学生用户,可以注册登录,查询个人成绩;作为管理员用户,可以注册登录,对学生信息进行各项操作。
资源推荐
资源详情
资源评论
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#include<conio.h>
#include<windows.h>
#include<ctype.h>
struct student
{
int id;
char name[10];
char age[10];
char birthday[15];
char add[15];
int math;
int Chinese;
struct student *next;
};
struct student *creat_inf() //创建基本信息单链表
{
struct student *head,*current,*stu;
int i=0;
char choice;
head=(struct student *)malloc(sizeof(struct student));
head->next=NULL;
current=head;
do
{
stu=(struct student *)malloc(sizeof(struct student));
#include<stdlib.h>
#include<string.h>
#include<conio.h>
#include<windows.h>
#include<ctype.h>
struct student
{
int id;
char name[10];
char age[10];
char birthday[15];
char add[15];
int math;
int Chinese;
struct student *next;
};
struct student *creat_inf() //创建基本信息单链表
{
struct student *head,*current,*stu;
int i=0;
char choice;
head=(struct student *)malloc(sizeof(struct student));
head->next=NULL;
current=head;
do
{
stu=(struct student *)malloc(sizeof(struct student));
printf("\004\004\004\004\004\004\004\004\004\004\004\004\004\n");
printf("第%d个人的信息:\n",++i);
printf("\004\004\004\004\004\004\004\004\004\004\004\004\004\n");
printf("学号:");
scanf("%d",&stu->id);
printf("\n姓名:");
scanf("%s",stu->name);
printf("\n年龄:");
scanf("%s",stu->age);
printf("\n生日:");
scanf("%s",stu->birthday );
printf("\n住址:");
scanf("%s",stu->add);
printf("\n数学:");
scanf("%d",&stu->math);
printf("\n语文:");
scanf("%d",&stu->Chinese);
current->next=stu; //尾插新结点
current=stu; //指向尾结点
printf("Continue?(Y/N)");
choice=getch();
}while(choice=='Y'||choice=='y');
current->next=NULL;
return(head);
}
void save_inf(struct student *h) //将单链表中的信息保存到指定的磁盘文件中
{
struct student *stu;
FILE *fp;
char filename[20];
printf("第%d个人的信息:\n",++i);
printf("\004\004\004\004\004\004\004\004\004\004\004\004\004\n");
printf("学号:");
scanf("%d",&stu->id);
printf("\n姓名:");
scanf("%s",stu->name);
printf("\n年龄:");
scanf("%s",stu->age);
printf("\n生日:");
scanf("%s",stu->birthday );
printf("\n住址:");
scanf("%s",stu->add);
printf("\n数学:");
scanf("%d",&stu->math);
printf("\n语文:");
scanf("%d",&stu->Chinese);
current->next=stu; //尾插新结点
current=stu; //指向尾结点
printf("Continue?(Y/N)");
choice=getch();
}while(choice=='Y'||choice=='y');
current->next=NULL;
return(head);
}
void save_inf(struct student *h) //将单链表中的信息保存到指定的磁盘文件中
{
struct student *stu;
FILE *fp;
char filename[20];
剩余23页未读,继续阅读
资源评论
自然醒。
- 粉丝: 41
- 资源: 7
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功