导航:首页 > 电脑系统 > 学生管理系统的电脑版

学生管理系统的电脑版

发布时间:2022-07-01 23:57:08

Ⅰ 有什么好用的学生管理系统软件适合学校用的

有什么好用的学生管理系统软件适合学校用。我觉得学校用的软件现在学校都正在用呢,你可以到学校去问一问,每个学校都有,不用上这上面问。

Ⅱ 设计一个学生信息管理系统

#include #include #include #define MAX 1000 /*定义学生成绩信息结构*/ struct stu { char id[8]; char name[8]; double Chinese; double Math; double English; double average; double total; }; /*学生结构数组,用于存储学生成绩信息*/ struct stu students[MAX]; /*当前学生人数*/ int current; void input() { int i; printf("请输入学生人数:"); scanf("%d", & current); for (i = 0; i < current; i++) { printf("\n请输入学生学号,最多为7位数: "); scanf("%s", students[i].id); printf("请输入学生姓名:"); scanf("%s", students[i].name); printf("请输入语文成绩:"); scanf("%lf", &students[i].Chinese); printf("请输入数学成绩:"); scanf("%lf", &students[i].Math); printf("请输入英语成绩:"); scanf("%lf", &students[i].English); students[i].total = students[i].Chinese + students[i].Math + students[i].English; students[i].average = students[i].total / 3; } } /*排名次,即对学生结构数组排序*/ void sort(struct stu array[], int n) { int i, j; struct stu temp; for (i = 0; i < n; i++) { for (j = i+1; j < n; j++) { if (array[i].average - array[j].average < 1e-16) { temp = array[i]; array[i] = array[j]; array[j] = temp; } } } } /*统计平均成绩,并输出各分数段的人数*/ void print_score(struct stu array[], int n) { int i; double ave = 0; int sum1 = 0, sum2 = 0, sum3 = 0, sum4 = 0; for (i = 0; i < n; i++) { ave += array[i].average; switch ((int)(array[i].average / 10)) { case 10: case 9: sum1++; break; case 8: sum2++; break; case 7: case 6: sum3++; break; default: sum4++; } } printf("全班的平均分为:%.1f\n", ave/n); printf("平均分在90分以上的人数为:%d\n", sum1); printf("平均分在80~89的人数为:%d\n", sum2); printf("平均分在60~79的人数为:%d\n", sum3); printf("平均分在60分以下的人数为:%d\n", sum4); } /*输出不及格科目及学生名单*/ void print_unreach(struct stu array[], int n) { int i; printf("科目\t学号\t名字\n"); for (i = 0; i < n; i++) { if (array[i].Chinese < 60) { printf("语文\t%s\t%s\n", array[i].id, array[i].name); } if (array[i].Math < 60) { printf("数学\t%s\t%s\n", array[i].id, array[i].name); } if (array[i].English 60) { printf("英语\t%s\t%s\n", array[i].id, array[i].name); } } } /*打印优等生名单*/ void print_good(struct stu array[], int n) { int i; char mark = 0; if (n > 3) { n = 3; } printf("学号\t姓名\t语文\t数学\t英语\t平均分\t名次\n"); for (i = 0; i n; i++) { if ((array[i].Chinese > 60) && (array[i].Math > 60) && (array[i].English > 60)) { if (array[i].average > 90) mark = 1; else if (array[i].average > 85) { if (array[i].Chinese == 100) mark = 1; if (array[i].Math == 100) mark = 1; if (array[i].English == 100) mark = 1; if (array[i].Chinese > 95 && array[i].English > 95) mark = 1; if (array[i].Chinese > 95 && array[i].Math > 95) mark = 1; if (array[i].Math > 95 && array[i].English > 95) mark = 1; } if (mark == 1) { printf("%s\t%s\t", array[i].id, array[i].name); printf("%.f\t%.f\t%.f\t%.1f\t", array[i].Chinese, array[i].Math, array[i].English, array[i].average); printf("%d\n", i+1); } } } } /*按学生姓名查询成绩*/ void search_name(struct stu array[], int n, char* name) { int i; char mark = 1; for (i = 0; i < n; i++) { if (strcmp(name, array[i].name) == 0) { printf("学生姓名:%s\n", name); printf("学生学号:%s\n", array[i].id); printf("语文:%.f\n", array[i].Chinese); printf("数学:%.f\n", array[i].Math); printf("英语:%.f\n", array[i].English); printf("平均分:%.1f\n", array[i].average); mark = 0; } } if (mark == 1) puts("不存在该学生记录"); } /*按学生学号查询成绩*/ void search_id(struct stu array[], int n, char* id) { int i; char mark = 1; for (i = 0; i < n; i++) { if (strcmp(id, array[i].id) == 0) { printf("学生姓名:%s\n", array[i].name); printf("学生学号:%s\n", array[i].id); printf("语文:%.f\n", array[i].Chinese); printf("数学:%.f\n", array[i].Math); printf("英语:%.f\n", array[i].English); printf("平均分:%.1f\n", array[i].average); mark = 0; break; } } if (mark == 1) puts("不存在该学生记录"); } void print_menu() { system("cls"); printf("1.输入学生信息\n"); puts("2.统计全班学生成绩"); puts("3.按学号查询学生成绩"); puts("4.按姓名查询学生成绩"); puts("5.输出不及格情况"); puts("6.输出优等生名单"); puts("0.退出本程序"); printf("\n\n 请输入你的选择:"); } int main(int argc, char **argv) { char ch = 0; char id[8], name[8]; while (ch != '0') { print_menu(); ch = getchar(); switch (ch) { case '1': { system("cls"); input(); sort(students, current); break; } case '2': { system("cls"); print_score(students, current); break; } case '3': { system("cls"); printf("请输入学号:"); scanf("%s", id); search_id(students, current, id); break; } case '4': { system("cls"); printf("请输入姓名:"); scanf("%s", name); search_name(students, current, name); break; } case '5': { system("cls"); print_unreach(students, current); break; } case '6': { system("cls"); print_good(students, current); break; } case '0': exit(0); } printf("\n\n按任意键返回主菜单……"); getchar(); getchar(); } return 0; }

Ⅲ C语言学生管理系统

#include<stdio.h>
#include<string.h>
#include<stdlib.h>
#include<conio.h>

#define max 20

typedef struct student //学生
{
char sno[max]; // 学号
char sname[max]; //姓名
char sex[max]; //性别
char age[max]; //年龄
char depart[max]; //系
char classs[max]; //班
char grade[max]; //年级

struct student* next;
} student;

student* head;

int LogOn() //登录模块,已实现输入密码不回显,如果中途发现输错某几位,可退格键重输
{
char username[max],password[max];
printf("\n请输入用户名:");
scanf("%s",username);
printf("\n请输入密码(最多15位):");

//开始以不回显且支持退格方式获取输入密码
int i=0;
while((i>=0)&&(password[i++]=getch())!=13)//条件i>=0是用于限制退格的范围
{
if(password[i-1]=='\b')//对退格键的处理
{
printf("%c%c%c",'\b','\0','\b');
i=i-2;
}
else
printf("*");
}
password[--i]='\0';

//已获取密码。验证用户身份
if(!strcmp(username,"zhang")&&!strcmp(password,"8147086"))
{
printf("\n登录成功!");
return 1;
}
else
return 0;

}

void regist()
{
char ch;
student *s,*ptr; //s用来建新结点,ptr用来暂存头结点

do
{

s=(student*)malloc(sizeof(student)); // 新建一个学生结点

printf("\n开始注册..."); //开始注册
printf("\n请输入该学生的学号:");
scanf("%s",s->sno);
printf("\n请输入该学生的姓名:");
scanf("%s",s->sname);
printf("\n请输入该学生的性别:");
scanf("%s",s->sex);
printf("\n请输入该学生的年龄:");
scanf("%s",s->age);
printf("\n请输入该学生的系:");
scanf("%s",s->depart);
printf("\n请输入该学生所在的班:");
scanf("%s",s->classs);
printf("\n请输入该学生所在的年级");
scanf("%s",s->grade);

ptr=head;
head=s;//将新结点插入队头
s->next=ptr;

fflush(stdin);
printf("\n请问是否继续注册?(Y/N)");
scanf("%c",&ch);
}while(ch=='Y'||ch=='y');

return;
}

void ElePrint(char str[]) //输出单个元素
{
if(str==NULL) exit(0);
printf("%s",str);
for(unsigned int i=0;i<12-strlen(str);i++) printf(" ");//为了对齐输出,需插入一些空格
return;
}

int LinePrint(student *ptr) //输出一行
{
if(ptr==NULL) //检查传进来的指针
return 0;

printf("\n");
ElePrint(ptr->sno);
ElePrint(ptr->sname);
ElePrint(ptr->age);
ElePrint(ptr->sex);
ElePrint(ptr->depart);
ElePrint(ptr->classs);
ElePrint(ptr->grade);

return 1;
}

void print() //输出全部学生信息
{
student *ptr=head;
printf("\n学号 姓名 年龄 性别 系 班 年级 ");
while(ptr)
{
LinePrint(ptr);
ptr=ptr->next;
}
printf("\n");
return;
}
void search()//查询模块
{
int method;//查询方式
char no[max],name[max],departm[max],clss[max],grades[max]; //用来接收查询关键字
while(1)
{
printf("\n请选择查询方式");
printf("\n1.按学号查询");
printf("\n2.按姓名查询");
printf("\n3.按所在系查询");
printf("\n4.按所在班级查询");
printf("\n5.按所在年级查询");
printf("\n6.打印全部学生信息");
printf("\n7.返回主菜单\n");

scanf("%d",&method);

student *p=head,*temp;

switch(method)
{
case 1:
printf("\n请输入要查询的学号:");
scanf("%s",no);
while(p)
{
if(!strcmp(p->sno,no))
break;
else
{
temp=p;
p=p->next;
}
}
printf("\n学号 姓名 年龄 性别 系 班 年级 ");
LinePrint(p);
break;
case 2:
printf("\n请输入要查询的姓名:");
scanf("%s",name);
printf("\n学号 姓名 年龄 性别 系 班 年级 ");
while(p)
{
if(!strcmp(p->sname,name))
LinePrint(p);
p=p->next;
}
break;
case 3:
printf("\n请输入学生所在的系:");
scanf("%s",departm);
printf("\n学号 姓名 年龄 性别 系 班 年级 ");
while(p)
{
if(!strcmp(p->depart,departm))
LinePrint(p);
p=p->next;
}
break;
case 4:
printf("\n请输入学生所在的班:");
scanf("%s",clss);
printf("\n请输入学生所在的年级:");
scanf("%s",grades);
printf("\n学号 姓名 年龄 性别 系 班 年级 ");
while(p)
{
if(!strcmp(p->classs,clss)&&!strcmp(p->grade,grades))
LinePrint(p);
p=p->next;
}
break;

case 5:
printf("\n请输入学生所在的年级:");
scanf("%s",grades);
printf("\n学号 姓名 年龄 性别 系 班 年级 ");
while(p)
{
if(!strcmp(p->grade,grades))
LinePrint(p);
p=p->next;
}
break;

case 6:
print();
break;

case 7:
return;
default:
printf("很抱歉,暂无此查询方式!");
break;
}
}

}

void modify()//修改学生信息
{
char num[max];
student *p=head;
printf("\n请输入要修改的学生的学号:");
scanf("%s",num);
while(p)
{
if(!strcmp(p->sno,num))
break;
else
p=p->next;
}
if(p==NULL)
{
printf("\n错误:没有此学生的信息!\n");
return;

}
LinePrint(p);

printf("\n请输入要修改的该学生的信息:");
printf("\n1.姓名");
printf("\n2.性别");
printf("\n3.年龄");
printf("\n4.所在的系");
printf("\n5.所在的班");
printf("\n6.所在的年级");

char name1[max],sex1[max],age1[max],depart1[max],class1[max],grade1[max];
int select;
fflush(stdin);
scanf("%d",&select);
printf("\n请输入新的信息:");

switch(select)
{
case 1:
scanf("%s",name1);
strcpy(p->sname,name1);
break;
case 2:
scanf("%s",sex1);
strcpy(p->sex,sex1);
break;
case 3:
scanf("%s",age1);
strcpy(p->age,age1);
break;
case 4:
scanf("%s",depart1);
strcpy(p->depart,depart1);
break;
case 5:
scanf("%s",class1);
strcpy(p->classs,class1);
break;
case 6:
scanf("%s",grade1);
strcpy(p->grade,grade1);
break;
default:
printf("\nError!");
break;
}

LinePrint(p);
return;
}

void del()// 删除某学生的信息
{
student *p=head,*temp=head,*s;
char num1[max];
printf("\n请输入要删除的学生的学号:");
scanf("%s",num1);
while(p)//查找该学生所在的结点
{
if(!strcmp(p->sno,num1))
break;
else
{
temp=p;
p=p->next;
}

}//while
if(!p)
{
printf("\n不存在此学生的信息.");
return;
}
LinePrint(p);//输出该学生的信息
printf("\n请问真的要删除该学生的信息吗?(Y/N)");
char ch;
fflush(stdin);
scanf("%c",&ch);
if(ch=='Y'||ch=='y')
{
s=p->next;
temp->next=s;
free(p);
printf("\n已经删除该学生的信息.");
}
return;
}

void sort() //排序模块。将学生记录按学号从小到大排列。用起泡排序算法实现
{

student *ptr,*s=head,*p;
int count=0,count1;
while(s)//统计链表结点个数
{
count++;
s=s->next;
}

for(int i=1;i<count;i++)
{
ptr=head;
p=NULL;
count1=count-i; //用来控制每轮起泡排序的终点,即每次把学号最小的结点移到倒数第i个结点
while(ptr&&ptr->next&&(count1--))
{
if(strcmp(ptr->sno,ptr->next->sno)>0)
{
s=ptr->next;
ptr->next=s->next;
if(p==NULL) //ptr处于队头时
head=s;
else
p->next=s;
s->next=ptr;
p=s;
}
else
{
ptr=ptr->next;
if(p==NULL) //ptr处于队头时
p=head;
else
p=p->next;
}
}
}
return;
}

void quit()
{
char ch;
printf("\n真的要退出?(Y/N)");
fflush(stdin);
scanf("%c",&ch);
if(ch=='Y'||ch=='y')
exit(0);
return;
}

int main()
{
int option;

printf("\nCopyright@2005 KongXinCai All rights reserved.");
printf("\n欢迎使用学生信息管理系统!\n");

//登录模块
int icheck=0;
while(icheck<3)
{
if(LogOn()==0)
icheck++;
else
break;

}
if(icheck==3)
{
printf("\n连续登录三次不成功,退出!");
exit(0);
}

//系统界面

while(1)
{
printf("\n\n请选择需要的服务:");
printf("\n1.注册");
printf("\n2.查询");
printf("\n3.修改");
printf("\n4.删除");
printf("\n5.排序");
printf("\n7.求平均");
printf("\n6.退出\n");

scanf("%d",&option);

switch(option)
{
case 1:
regist();
break;
case 2:
search();
break;
case 3:
modify();
break;
case 4:
del();
break;
case 5:
sort();
break;
case 6:
quit();
break;
}

}

return 0;

}

Ⅳ 学生管理系统

#include<iostream>
#include<cstring>
#include<fstream>
using namespace std;

int num=0;
const int MAX_NUM_OF_STUDENTS=1000;

struct Student
{
char name[20],sex[10],bonetime[20],address[20],mail[20];
int no,age,phone;

};
Student students[MAX_NUM_OF_STUDENTS];
Student name_students[MAX_NUM_OF_STUDENTS];

char choose;
extern int Input_project();
extern int Search_project();
extern int Delete_project();
extern int Modify_project();

int Face()//主界面
{
cout<<"***********欢迎使用学生信息管理系统************"<<endl<<endl;
cout<<"◇ 录入(I),"<<endl<<"◇ 查询(S),"<<endl<<"◇ 删除(D),"<<endl
<<"◇ 修改(M),"<<endl<<"◇ 退出(E),"<<endl;
cout<<"☆ 请输入您的选择(I,S,D,E):";

cin>>choose;

switch(choose)
{ case 'I':
case 'i': system("cls");Input_project();break;
case 'S':
case 's': system("cls");Search_project();break;
case 'D':
case 'd': system("cls");Delete_project();break;
case 'M':
case 'm': system("cls");Modify_project();break;
case 'E':
case 'e': system("cls");return -1;break;
default: cout<<" 输入错误!"<<endl;
}
return 0;
}
int Input_project()//输入功能
{
choose='C';
while( choose=='C'||choose=='c')
{
num++;
cout<<"请输入学号:";
cin>>students[num].no;
cout<<"请输入姓名:";
cin>>students[num].name;
cout<<"请输入年龄:";
cin>>students[num].age;
cout<<"请输入性别:";
cin>>students[num].sex;
cout<<"请输入出生年月:";
cin>>students[num].bonetime;
cout<<"请输入地址:";
cin>>students[num].address;
cout<<"请输入电话号码:";
cin>>students[num].phone;
cout<<"请输入E-mail:";
cin>>students[num].mail;
cout<<"☆ 继续或返回主菜单(C/E):";

cin>>choose;

if(choose=='E'||choose=='e') break;
}

num+=1;
int i=num;//以下是按no冒泡排序
bool exchange;
while(i>1)
{ exchange=false;
for( int k=0;k<i-1;k++)
{ if(students[k].no>students[k+1].no)
{ Student temp=students[k];
students[k]=students[k+1];
students[k+1]=temp;
exchange=true;
}
}
if (!exchange) break;
i--;
}

for (int t=0;t<num;t++)//结构体数组各项一一复制
{ name_students[t].no=students[t].no;
*strcpy(name_students[t].name,students[t].name);
name_students[t].age=students[t].age;
*strcpy(name_students[t].sex,students[t].sex);
*strcpy(name_students[t].bonetime,students[t].bonetime);
*strcpy(name_students[t].address,students[t].address);
name_students[t].phone=students[t].phone;
*strcpy(name_students[t].mail,students[t].mail);
}

while(i>1)//以下是按name冒泡排序
{ exchange=false;
for( int k=0;k<i-1;k++)
{ if(strcmp(name_students[k].name,name_students[k+1].name)>0)
{ Student temp=name_students[k];
name_students[k]=name_students[k+1];
name_students[k+1]=temp;
exchange=true;
}
}
if (!exchange) break;
i--;
}

FILE *fp=fopen("c:\\name.txt","a+");//存储两结构体数组
FILE *fp1=fopen("c:\\number.txt","a+");

if (fp == NULL||fp1 == NULL)//判断文件打开是否成功
{
cout<<"打开文件失败!"<<endl;
return -1;
}
for(i=0;i<num;i++)
{
fwrite(&students[i],sizeof(Student),1,fp);
fwrite(&name_students[i],sizeof(Student),1,fp1);
}
fclose(fp);
fclose(fp1);
system("cls");return 0;
}
int Search_project()//查询功能
{
FILE *fp=fopen("c:\\name.txt","r");
FILE *fp1=fopen("c:\\number.txt","r");
if (fp == NULL||fp1 == NULL)//判断文件打开是否成功
{
cout<<"打开文件失败!"<<endl;
return -1;
}
num=0;

fread(&students[num],sizeof(Student),1,fp);
fread(&name_students[num],sizeof(Student),1,fp1);
while((!feof(fp))&&(!feof(fp1)))
{
num++;//计算已存储的资料的人数num
fread(&students[num],sizeof(Student),1,fp);
fread(&name_students[num],sizeof(Student),1,fp1);
}
fclose(fp);
fclose(fp1);

cout<<'\t'<<"按学号查询(A)"<<'\t'<<"按姓名查询(B)"<<'\t'<<"返回主菜单(E)"<<endl;
cout<<"Ο 请选择:";
char input;
cin>>input;

switch(input)
{
case 'A':
case 'a':
{
cout<<"请输入学号:";
int number;
cin>>number;//以下是折半查询:
int low=0;
int high=num-1;
while (low<=high)
{
int mid=(low+high)/2;
if (students[mid].no==number)
{
cout<<" 学号:"<<students[mid].no<<endl;
cout<<" 姓名:"<<students[mid].name<<endl;
cout<<" 年龄: "<<students[mid].age<<endl;
cout<<" 性别: "<<students[mid].sex<<endl;
cout<<"出生年月: "<<students[mid].bonetime<<endl;
cout<<" 地址: "<<students[mid].address<<endl;
cout<<"电话号码: "<<students[mid].phone<<endl;
cout<<" E-mail: "<<students[mid].mail<<endl;

break;
}
else if (number>students[mid].no)
low=mid+1;
else high=mid-1;
}
if(low>high) cout<<" 无相关资料!"<<endl;
}
break;

case 'B':
case 'b':
{
cout<<"请输入姓名:";
char name[20];
cin>>name;
int low=0;
int high=num-1;//以下是折半查询:
while (low<=high)
{
int mid=(low+high)/2;
if (strcmp(name_students[mid].name,name)==0)
{
cout<<" 学号:"<<name_students[mid].no<<endl;
cout<<" 姓名:"<<name_students[mid].name<<endl;
cout<<" 年龄: "<<name_students[mid].age<<endl;
cout<<" 性别: "<<name_students[mid].sex<<endl;
cout<<" 出生年月: "<<name_students[mid].bonetime<<endl;
cout<<" 地址: "<<name_students[mid].address<<endl;
cout<<" 电话号码: "<<name_students[mid].phone<<endl;

cout<<" E-mail: "<<name_students[mid].mail<<endl;
break;
}
else if (strcmp(name_students[mid].name,name)<0)
low=mid+1;
else high=mid-1;
}
if(low>high) cout<<" 无相关资料!"<<endl;
}
break;
case 'E':
case 'e':
system("cls");
return -1;break;
}

cout<<"☆ 继续或返回主菜单(C/E):";

cin>>choose;
if(choose=='C'||choose=='c')
{
system("cls");
Search_project();
}
else
{
system("cls");
return -1;
}
return 0;
};

int Delete_project()
{
cout<<'\t'<<"按学号删除(A)"<<'\t'<<"按姓名删除(B)"<<'\t'<<"返回主菜单(E)"<<endl;
cout<<" 请选择:";
char input;
cin>>input;

switch(input)
{
case 'A':
case 'a':
cout<<" 需删除的学生的学号是:";
int number;
cin>>number;
for(int i=0;i<num;i++)
{
if( students[i].no==number)
break;
}
for(int j=i;j<num;j++)//将要删除的学生调至数组最后一位,前num-1位仍按no排列
{
Student temp =students[j];
students[j]=students[j+1];
students[j+1]=temp;
}
case 'B':
case 'b':
cout<<" 需删除的学生的姓名是:";
char name[20];
cin>>name;
for(int t=0;t<num;t++)
{
if(strcmp(name_students[t].name,name)==0)
break;
}
for(int j=t;j<num;j++)//将要删除的学生调至数组最后一位,前num-1位仍按name排列
{
Student temp =name_students[j];
name_students[j]=name_students[j+1];
name_students[j+1]=temp;
}
num-=1;//总人数减一,即删除最后一位

FILE *fp=fopen("c:\\name.txt","w");
FILE *fp1=fopen("c:\\number.txt","w");
if (fp == NULL||fp1 == NULL)//判断文件打开是否成功
{
cout<<"打开文件失败!"<<endl;
return -1;
}
for(i=0;i<num;i++)
{
fwrite(&students[i],sizeof(Student),1,fp);
fwrite(&name_students[i],sizeof(Student),1,fp1);
}
fclose(fp);
fclose(fp1);

bool p=true;//以下查找并判断删除是否成功
int low=0;
int high=num-1;
while (low<=high)
{
int mid=(low+high)/2;
if (students[mid].no==number||name_students[mid].no==number)
{
cout<<" 删除失败!"<<endl;
p=false;
break;
}
else if (number>students[mid].no)
low=mid+1;
else high=mid-1;
}
if(p)
cout<<" 删除成功!"<<endl;
cout<<"☆ 继续或返回主菜单(C/E):";

cin>>choose;
if(choose=='C'||choose=='c')
{
system("cls");Delete_project();
}
else
{
system("cls");return -1;
}
return 0;
};

int Modify_project()
{
FILE *fp=fopen("c:\\name.txt","r");
FILE *fp1=fopen("c:\\number.txt","r");
if (fp == NULL||fp1 == NULL)//判断文件打开是否成功
{
cout<<"打开文件失败!"<<endl;
return -1;
}
num=0;
fread(&students[num],sizeof(Student),1,fp);
fread(&name_students[num],sizeof(Student),1,fp1);
while((!feof(fp))&&(!feof(fp1)))
{
num++;//计算已存储的资料的人数num
fread(&students[num],sizeof(Student),1,fp);
fread(&name_students[num],sizeof(Student),1,fp1);
}
fclose(fp);
fclose(fp1);

cout<<" 需修改的学生的学号是:";
int number;
cin>>number;
int t,math,english,physics,computer;
cout<<" 输入修改结果:"<<endl;
cout<<" 姓名:";
cin>>name;
cout<<" 年龄:";
cin>>age;
cout<<" 性别:";
cin>>sex;
cout<<" 出生年月:";
cin>>bonetime;
cout<<" 地址:";
cin>>address;
cout<<" 电话号码:";
cin>>phone;
cout<<" E-mail:";
cin>>mail;
for(int i=0;i<num;i++)
{
if( students[i].no==number)
break;
}
students[i].name=name;
students[i].age=age;
students[i].sex=sex;
students[i].bonetime=bonetime;
students[i].address=address;
students[i].phone=phone;
students[i].mail=mail;

i=num;//以下是按no冒泡排序
bool exchange;
while(i>1)
{
exchange=false;
for( int k=0;k<i-1;k++)
{
if(students[k].no>students[k+1].no)
{
Student temp=students[k];
students[k]=students[k+1];
students[k+1]=temp;
exchange=true;
}
}
if (!exchange) break;
i--;
}

for (t=0;t<num;t++)//结构体数组各项一一复制
{
name_students[t].no=students[t].no;
*strcpy(name_students[t].name,students[t].name);
name_students[t].age=students[t].age;
name_students[t].sex=students[t].sex;
name_students[t].bonetime=students[t].bonetime;
name_students[t].address=students[t].address;
name_students[t].phone=students[t].phone;
name_students[t].mail=students[t].mail;
}
while(i>1)//以下是按name冒泡排序
{
exchange=false;
for( int k=0;k<i-1;k++)
{
if(strcmp(name_students[k].name,name_students[k+1].name)>0)
{
Student temp=name_students[k];
name_students[k]=name_students[k+1];
name_students[k+1]=temp;
exchange=true;
}
}
if (!exchange) break;
i--;
}

fp=fopen("c:\\name.txt","w+");//存储两结构体数组,w+表示清空已有文件的内容
fp1=fopen("c:\\number.txt","w+");
if (fp == NULL||fp1 == NULL)//判断文件打开是否成功
{
cout<<"打开文件失败!"<<endl;
return -1;
}
for(i=0;i<num;i++)
{
fwrite(&students[i],sizeof(Student),1,fp);
fwrite(&name_students[i],sizeof(Student),1,fp1);
}
fclose(fp);
fclose(fp1);
cout<<"☆ 继续或返回主菜单(C/E):";

cin>>choose;
if(choose=='C'||choose=='c')
{
system("cls");Delete_project();}
else {system("cls");return -1;}
return 0;
};

int main()
{
system("cls");
do
{Face();}
while (choose=='e'||choose=='E');
return 0;
system("pause");
}

Ⅳ 学生管理系统程序

这个不难 自己做 再说你也没说用什么语言,数据库开发 CS /BS

Ⅵ 学生信息管理系统(C语言版)

#include "stdio.h"
#include "bios.h"
#include "conio.h"
#include "STRING.H"
#include "DOS.h"
#include "process.h"
#include "stdlib.h"
#include "math.h"
#define key_down 80
#define key_up 72
#define key_esc 1
#define key_alt_f 33
#define key_alt_x 45
#define key_enter 28
#define key_alt_c 46
#define key_alt_e 18
#define key_alt_s 31
#define key_alt_d 32
#define key_alt_r 19
#define key_alt_p 25
#define key_alt_o 24
struct student
{
char name[20];
long num;
char age[2];
char sex[4];
char xibie[16];
char jiguan[50];
struct{
float chinese;
float english;
float math;
float total;
float ave;}score;
struct student *next;
};
struct student agent[50];
struct student *head,*this1,*new1,*new2,*stud;
char numstr[40]={' ',' '};
int n=0;
int r=0;
int k=0;
long num;
int get_key();
void box(int startx,int starty,int high,int width);
void new1name(void),listall(void),wfile(void),rfile(void);
struct student *insert(struct student *head ,struct student *stud);
void cjlr(),cjtj(),cjpx(),cxxs(),list(),cxcj();
void del();
int mmm();
int nnn();
void ab();
mmm()
{char aaa[6],bbb[6];
char d; //int r=0;
int i=0;
FILE *fp;
char a[6];
char b[6];
clrscr();
if((fp=fopen("file1","r"))==NULL)
{ window(1,1,80,25);
textbackground(1);
textcolor(0);
clrscr();
window(20,8,60,20);
textbackground(14);
textcolor(0);
clrscr();
gotoxy(8,2);
cprintf("NO UER!");
fclose(fp);
fp=fopen("file1","w");
gotoxy(2,4);
printf("Please input name:");
gets(a);fwrite(a,6,1,fp);
gotoxy(2,8);
printf("Please input key:");
gets(b); fwrite(b,6,1,fp);
fclose(fp);
ab();
}
else
{ window(1,1,80,25);
textbackground(1);
textcolor(0);
clrscr();
window(20,8,60,20);
textbackground(14);
textcolor(0);
clrscr();
gotoxy(8,2);
cprintf("Input Your Name And Password:");
gotoxy(2,8);
cprintf(" PWD:");
gotoxy(2,4);
cprintf("NAME:");
scanf("%s",aaa);

gotoxy(7,8);
while(d=getch())
{
if(d==13)
break;
cprintf("*");
bbb[i]=d;
i++;
}
fp=fopen("file1","r");
fread(a,6,1,fp);
fread(b,6,1,fp);
fclose(fp);
for(i=0;i<=5;i++)
{
if(aaa[i]!=a[i] || bbb[i]!=b[i])
exit(0);

}

}

ab();

}
nnn()
{union REGS inregs ,outregs;
inregs.h.ah=0x2a;
intdos(&inregs,&outregs);
window(60,24,80,25);
textbackground(14);
textcolor(0);
clrscr();
cprintf("Data is 2004-%d-%d.\n",outregs.h.dh,outregs.h.dl);
return 0;
}

void ab()
{int i;
clrscr();
window(1,1,80,25);
textbackground(1);
textcolor(0);
clrscr();
window(20,8,62,20);
textbackground(14);
textcolor(128);
clrscr();
for(i=0;i<=11;i++)
{window(20,8+i,62,9+i);
textbackground(i);
textcolor(128+i*2);
clrscr();
cprintf(" Welcome To Students Management System!");
}
getch();
}
main()
{int i,key,x,y,l;
char *menu[]={"input(F)","print1(O)","del(D)","find(C)","print(P)","save(S)","exit(X)"};
char *red[]={"input","printf1","del","find","print","cpoy","exit"};
char *f[]={"xueji luru","chengji luru","chenji tongji","add student","chengji paixu"};
char *c[]={"student","chengji"};
char buf[16*10*4],buf1[16*4];
struct student *stud;
if(k++==0)
mmm();
window(1,2,80,25);
textbackground(15);
textcolor(0);
clrscr();
textbackground(1);
clrscr();
window(1,1,80,1);
textbackground(15);
textcolor(0);
clrscr();
window(1,1,80,2);
gotoxy(1,1);
for(i=0,l=0;i<7;i++)
{x=wherex();
y=wherey();
cprintf(" %s",menu[i]);
l=strlen(menu[i]);
gotoxy(x,y);
textcolor(RED);
cprintf(" %s",red[i]);
x=x+l+4;
gotoxy(x,y);
textcolor(BLACK);
}
nnn();
if(r++==0)
main();
window(1,2,80,25);
while(1)
{
key=0;
while(bioskey(1)==0);
key=get_key();
if(key==key_alt_x) exit(0) ;
if(key==key_alt_s) wfile();
if(key==key_alt_d) del();
if(key==key_alt_r) rfile();
if(key==key_alt_p) listall();
if(key==key_alt_o) list();
if(key==key_alt_f)
{textbackground(0);
textcolor(15);
gotoxy(4,1);
cprintf("%s",menu[0]);
gettext(4,2,18,12,buf);
window(4,2,18,8);
textbackground(15);
textcolor(0);
clrscr();
window(4,2,19,9);
box(1,1,7,16);
for(i=2;i<7;i++)
{gotoxy(2,i);
cprintf("%s",f[i-2]);}
gettext(2,2,18,3,buf1);
textbackground(0);
textcolor(15);
gotoxy(2,2);
cprintf("%s",f[0]);
y=2;
key=get_key();
while(key!=key_alt_x && key!=key_enter && key!=key_esc)
{if(key==key_up || key==key_down)
{puttext(2,y,18,y+1,buf1);
if(key==key_up)
y=y==2?6:y-1;
if(key==key_down)
y=y==6?2:y+1;
gettext(2,y,18,y+1,buf1);
textbackground(0);
textcolor(15);
gotoxy(2,y);
cprintf("%s",f[y-2]);
}
key=get_key();
}
if(key==key_alt_x) exit(0);
if(key==key_enter)
{switch(y-1)
{case 1 : new1name();break;
case 2 : cjlr();break;
case 3 : cjtj();break;
case 4 : insert(head,stud);break;
case 5 : cjpx();break;
default : break;
}
}
}
else
{
window(1,1,80,1);
puttext(2,2,19,10,buf);
textbackground(15);
textcolor(0);
gotoxy(4,1);
cprintf("%s",menu[0]);

}
if(key==key_alt_c)
{textbackground(0);
textcolor(15);
gotoxy(39,1);
cprintf("%s",menu[3]);
gettext(39,2,50,7,buf1);
window(39,2,49,5);
textbackground(15);
textcolor(0);
clrscr();
window(39,2,49,6);
box(39,1,4,11);
for(i=2;i<4;i++)
{
gotoxy(2,i);
cprintf("%s",c[i-2]);
}
gettext(39,2,49,3,buf1);
textbackground(0);
textcolor(15);
gotoxy(2,2);
cprintf("%s",c[0]);
y=2;
key=get_key();
while(key!=key_alt_x&&key!=key_enter&&key!=key_esc)
{if(key==key_up||key==key_down)
{puttext(39,y,49,y+1,buf1);
if(key==key_up)
y=y==2?3:y-1;
if(key==key_down)
y=y==3?2:y+1;
gettext(39,y,49,y+1,buf1);
textbackground(0);
textcolor(15);
gotoxy(2,y);
cprintf("%s",c[y-2]);
}
key=get_key();
}
if(key==key_alt_x) exit(0);
if(key==key_enter)
{switch(y-1)
{case 1: cxxs();break;
case 2: cxcj();break;

default:break;
}
}
}
else
{window(1,1,80,2);
puttext(39,2,49,7,buf);
textbackground(15);
textcolor(0);
gotoxy(39,1);
cprintf("%s",menu[3]);

}
} }

int get_key()
{ union REGS rg;
rg.h.ah=0;
int86(0x16,&rg,&rg);
return rg.h.ah;
}

void box(int startx,int starty,int high,int width)
{ int i;
gotoxy(startx,starty);
putch(0xda);
for(i=starty+1;i<width;i++)
putch(0xc4);
putch(0xbf);
for(i=starty+1;i<high;i++)
{gotoxy(startx,i);
putch(0xb3);
gotoxy(width,i);putch(0xb3);}
gotoxy(startx+1,width);
putch(0xc0);
for(i=startx+1;i<width;i++)
putch(0xc4);
putch(0xd9);
return;
}

/* void new1name(void)
{ int key;
window(1,2,80,25);
textbackground(BLUE);
clrscr();
cprintf("Are you sure input?");
key=get_key();
while(key!=key_alt_x && key!=key_esc)
{
window(1,2,80,25);
textbackground(BLUE);
clrscr();
new1=new2=(struct student *)malloc(sizeof(struct student));
if(head==NULL)
head=new1;
else
{ this1=head;
while(this1->next!=NULL)
this1=this1->next;
this1->next=new1;
}
this1=new1;
printf("\nRecord%d:",n+1);
printf("\nXing Ming:");
gets(this1->name);
printf("\nXue Hao:");
gets(numstr);
this1->num=atol(numstr);
printf("\nNian Ling:");
gets(this1->age);
printf("\nXing Bie:");
gets(this1->sex);
printf("\nXue Yuan:");
gets(this1->xibie);
printf("\nJi Guan:");
gets(this1->jiguan);
n++;
this1->next=NULL;
printf("Are you sure input :Y/N?");
if(getch()=='n')
main();
else
new1name();
}
} */

void new1name(void)
{ int key;
char a;
window(1,2,80,25);
textbackground(BLUE);
clrscr();
cprintf("Are you sure input?");
key=get_key();
while(key!=key_alt_x && key!=key_esc)
{
window(1,2,80,25);
textbackground(BLUE);
clrscr();
new1=new2=(struct student *)malloc(sizeof(struct student));
if(head==NULL)
head=new1;
else
{ this1=head;
while(this1->next!=NULL)
this1=this1->next;
this1->next=new1;
}
this1=new1;
printf("\nRecord%d:",n+1);
printf("\nXing Ming:");
gets(&a);
gets(this1->name);
printf("\nXue Hao:");
gets(numstr);
this1->num=atol(numstr);
printf("\nNian Ling:");
gets(this1->age);
printf("\nXing Bie:");
gets(this1->sex);
printf("\nXue Yuan:");
gets(this1->xibie);
printf("\nJi Guan:");
gets(this1->jiguan);
n++;
this1->next=NULL;
printf("Are you sure input :Y/N?");
if(getch()=='n')
main();
else
new1name();
}
main();
}
/**/
void listall(void)
{
int i=0;
window(1,2,80,25);
textbackground(1);
textcolor(0);
clrscr();
if(head==NULL)
{cprintf("\nempty list .\n");return;
}
this1=head;

do
{ cprintf("\nrecord number %d\n",++i);
cprintf(" name:%s",this1->name);
cprintf(" number:%ld",this1->num);
cprintf(" age:%s",this1->age);
cprintf(" sex:%s",this1->sex);
cprintf(" xibie:%s",this1->xibie);
cprintf(" jiguan:%s",this1->jiguan);
cprintf(" chinese:%6.2f",this1->score.chinese);
cprintf(" english:%6.2f",this1->score.english);
cprintf(" math:%6.2f",this1->score.math);
cprintf(" total:%6.2f",this1->score.total);
cprintf(" ave:%6.2f\n",this1->score.ave);
this1=this1->next;
//this1->next=NULL;
}while(this1!=NULL);
getch();
main();
}
//*insert
struct student *insert(struct student *head,struct student *stud)
{
struct student *p0,*p1,*p2;
p1=head;
p0=stud;
if(head==NULL)
{head=p0;p0->next=NULL;}
else
while((p0->num>p1->num) && (p1->next!=NULL))
{p2=p1;p1=p1->next;}
if(p0->num<=p1->num)
{if(head==p1)
{head=p0;
p0->next=p1;
}
else
{p2->next=p0;
p1->next=p1;
}
}
else
{p1->next=p0;
p0->next=NULL;
}
n=n+1;
return(head);
}
void wfile(void)
{FILE *fptr;
char a[10];
if(n<1)
{printf("\nCan't write empty list.\n");return;}
// char a[10];
cprintf("Please input filename:");
gets(a);
if((fptr=fopen(a,"wb"))==NULL)
printf("\nCant' open file agents.rec\n");
else
{this1=head;
while(this1->next!=NULL)
{fwrite(this1,sizeof(struct student ),1,fptr);
this1=this1->next;
}
// fwrite(this1,sizeof(struct student ),1,fptr);
fclose(fptr);
printf("\nFile of %d records have writen.\n",n);
}
getch();
main();
}
//*rfile
void rfile(void)
{FILE *fptr;
char b[10];
cprintf("Please input filename:");
gets(b);
if((fptr=fopen(b,"rb"))==NULL)
printf("\nCan't open file %s\n",b);
else
{n=0;
head=(struct student *)malloc(sizeof(struct student));
this1=head;
fread(this1,sizeof(struct student),1,fptr);
n++;
while(1)
{if(feof(fptr))
{fclose(fptr);
this1->next=NULL;printf("\nFile read.Total agents is now %d.\n",n);
getch(); main() ;
}else{
this1->next=(struct student *)malloc(sizeof(struct student));
this1=this1->next;
fread(this1,sizeof(struct student),1,fptr);
n++;
}} this1->next=NULL;

//fread(this1,sizeof(struct student),1,fptr);
//n++;
fclose(fptr);
printf("\nFile read.Total agents is now %d.\n",n);
}
getch();
main();
}
//*wfile
/*void wfile(void)
{char a[10];
FILE *fptr;
if(n<1)
{printf("\nCan't write empty list.\n");return;}
cprintf("Please input filename:");
gets(a);
if((fptr=fopen(a,"wb"))==NULL)
{cprintf("\nCant' open file ");puts(a);cprintf("\n");
}
else
{fwrite(agent,sizeof(struct student ),n,fptr);
fclose(fptr);
printf("\nFile of %d records writen.\n",n);
}
getch();
main();
}
//*rfile
void rfile(void)
{FILE *fptr;
char a[10];
cprintf("Please input filename:");
gets(a);
if((fptr=fopen(a,"wb"))==NULL)
{cprintf("\nCan't open file ");puts(a);
}
else
{while(fread(&agent[n],sizeof(agent[n]),1,fptr)==1)
n++;
fclose(fptr);
printf("\nFile read.Total agents is now %d.\n",n);
}
getch();
main();
} */
//*cjlr
void cjlr(void)
{struct student *p1;
long num; char ddd[5];
char ccc[5];
window(1,2,80,25);
textbackground(BLUE);
clrscr();
p1=head;
printf("input the student' number:");
scanf("%ld",&num);
if(head==NULL)
{
printf("\nlist null!\n");
}
p1=head;
while(num!=p1->num && p1->next!=NULL)
{p1=p1->next;}
if(p1->num==num)
{printf("chinese:");
scanf("%f",&p1->score.chinese);
// gets(ccc);printf("\n");
// p1->score.chinese=atof(ccc);
printf("english:");
scanf("%f",&p1->score.english);
// gets(numstr);
//p1->score.english=atof(numstr);
//getch();
printf("math:");
scanf("%s",ddd);
// gets(ddd);
p1->score.math=atof(ddd);
p1->score.total=p1->score.chinese+p1->score.english+p1->score.math;
p1->score.ave=(p1->score.chinese+p1->score.english+p1->score.math)/3.0;
}
getch();
main();
}
//*cjlr
/*void cjlr(void)
{struct student *p1;
long num; char ddd[4];
window(1,2,80,25);
textbackground(BLUE);
clrscr();
p1=head;
printf("input the student' number:");
scanf("%ld",&num);
if(head==NULL)
{
printf("\nlist null!\n");
}
p1=head;
while(num!=p1->num && p1->next!=NULL)
{p1=p1->next;}
if(p1->num==num)
{printf("chinese:");
scanf("%f",p1->score.chinese);
//gets(numstr);
//p1->score.chinese=atof(numstr);
//getch();
printf("english:");
scanf("%f",p1->score.english);
//gets(numstr);
//p1->score.english=atof(numstr);
// getch();
printf("math:");
//scanf("%f",p1->score.math);
gets(ddd);
p1->score.math=atof(ddd);
p1->score.ave=(p1->score.chinese+p1->score.english+p1->score.math)/3.0;
getch();
}
getch();
main();
} */
//*del
void del()
{struct student *p1,*p2;
long num;
window(1,2,80,25);
textbackground(BLUE);
clrscr();
printf("input the del student' number:");
scanf("%ld",&num);
if(head==NULL)
{
printf("\nlist null!\n"); exit(1);
}
p1=head;
while(num!=p1->num && p1->next!=NULL)
{p2=p1;p1=p1->next;
}
if(num==p1->num)
{if(p1==head) head=p1->next;
else
p2->next=p1->next;
printf("the %ld message have del\n",num);
n=n-1;
}
else
printf("No find %ld!\n",num);
getch();
main();
}
//
void cjtj(void)
{struct student *p;
for(p=head;p!=NULL;p=p->next)
{ p->score.total=p->score.chinese+p->score.english+p->score.math;
p->score.ave=p->score.total/3.0;
}
}
//
void cjpx(void)
{
struct student *p,*p1;
int i,j,t;
float temp;
for(i=0;i<n;i++)
{

p=head;
p1=p->next;
if(p->score.total<p1->score.total)
{temp=p->score.total;
p->score.total=p1->score.total;
p1->score.total=temp;
}
}
}
//
void cxxs(void)
{ struct student *p;
char name1[20];
window(1,2,80,25);
textbackground(BLUE);
clrscr();
printf("shu ru yao cha xun de xue sheng de xing ming:");
gets(name1);
for(p=head;p!=NULL;p=p->next)
{if(strcmp(p->name,name1)==0)

{printf("xingming:%s\n",p->name);
printf("xuehao:%ld\n",p->num);
printf("nianling:%s\n",p->age);
printf("xingbie:%s\n",p->sex);
printf("xibie:%s\n",p->xibie);
printf("jiguan:%s\n",p->jiguan);
}
} getch();
main();
}
/*chaxunchengji*/
void cxcj(void)
{ struct student *p;
char name2[20]; int i;
window(1,2,80,25);
textbackground(BLUE);
clrscr();
printf("shu ru yao cha xu de xue sheng de xingming:");
gets(name2);
for(p=head;p!=NULL;p=p->next)
{if(strcmp(p->name,name2)==0)
{printf("xingming:%s\n",p->name);
printf("chinese:%6.2f\n",p->score.chinese);
printf("english:%6.2f\n",p->score.english);
printf("math:%6.2f\n",p->score.math);
printf("total:%6.2f\n",p->score.total);
printf("ave:%6.2f\n",p->score.ave);
}
}getch();
main();
}

/*dayingmugexueshen*/
void list(void)
{ char name3[20];
int i=0;
window(1,2,80,25);
textbackground(BLUE);
clrscr();
printf("shu ru yao da ying de xue sheng xingming:");
gets(name3);
if(head==NULL)
{ printf("\nempty list.\n");
return;
}
for(this1=head;this1!=NULL;this1=this1->next)
{
if(strcmp(this1->name,name3)==0)
{printf("\nnrecord number %d\n",++i);
printf("xingmming:%s\n",this1->name);
printf("xuehao:%ld\n",this1->num);
printf("nianling:%d\n",this1->age);
printf("xingbie:%s\n",this1->sex);
printf("xueyuan:%s\n",this1->xibie);
printf("jiguan:%s\n",this1->jiguan);
printf("chinese:%6.2f\n",this1->score.chinese);
printf("english:%6.2f\n",this1->score.english);
printf("math:%6.2f\n",this1->score.math);
printf("total:%6.2f\n",this1->score.total);
printf("ave:%6.2f\n",this1->score.ave);
}

} getch();
main();
}

Ⅶ 把别人做好的学生管理开发系统移到自己的电脑上需要怎么

别人做好的学生管理系统,如果想移植到自己的电脑上,首先。要得到完整的授权,并且要重建数据库目录,并且导入相关信息。

Ⅷ 学生管理软件哪个好用免费吗

这些软件基本都是免费的。

Ⅸ 实现简单的学生管理系统

该不会是c语言的课程设计吧,现在的教学还真是极端类似,当时学c我的课程设计也是这种,题目文字表述几乎不变,不过同学如果你是认真想学到c的话,你还是自己认真投入去编写吧,
这个题目要编写系统这几乎是包含C语言最简单也是最基础的几条命令,如果学了c,连最基础的都写不出来。那也就白学了

下面是一个当时没完成的半成品,刚好电脑里还保存这个文件,我不是专业学C的,下面的程序仅供你参考

#define N 2 //N为输入的学生数量
#include<stdio.h>

struct student
{
int num[10];
char sex[2];
char name[15];
char cla[12];
int score[3];
}stu[N+N+1];

void input(struct student stu[])
{
int i,j;
for(i=0;i<N;i++)
{
printf("\n请输入第%d个同学的信息:\n",i+1);
printf("\n学号:");
scanf("%d",stu[i].num);
printf("\n性别,男(女)性用b(g)表示:");
scanf("%s",stu[i].sex);
printf("\n姓名:");
scanf("%s",stu[i].name);
printf("\n班级:");
scanf("%s",stu[i].cla);
for(j=0;j<3;j++)
{
printf("\nscore %d:",j+1);
scanf("%d",&stu[i].score[j]);
}
printf("\n该学生输入完成!\n");
}
printf("\n 全部输入结束!\n");
}

void main()
{
void pp();
void input();
void xg();
void print();
void cl();
pp();
printf("\n");
printf("\n 操作完成,关闭窗口退出!\n\n");
}

void print(struct student stu[])
{
int i,j;
printf("\n学号 姓名 性别 班级 score1 score2 score3\n");
for(i=0;i<N;i++)
{
printf("%-15d%-15s%-10s%-10s",*stu[i].num,stu[i].name,stu[i].sex,stu[i].cla);
for(j=0;j<3;j++)
printf("%-9d",stu[i].score[j]);
printf("\n");
}
}

void pp()
{
int s ;
printf(" ★小型学生信息管理系统★\n");
do
{
printf("\n 主菜单\n");
printf("\n 1.数据输入 2.数据修改 3.数据处理 4.数据输出 5.退出\n");
printf("\n请输入您要执行的命令,用命令前的数字表示:");
scanf("%d",&s);
switch(s)
{
case 1 : input(stu);break;
case 2 : xg(stu);break;
case 3 : cl();break;
case 4 : print(stu);break;
}
}
while(s!=5);
}

void xg(struct student stu[])
{
int n,i,j,e;char f;
printf("\n请输入要修改的学生学号:");
scanf("%d",&n);getchar();
for(i=0;i<N;i++)
/*if(n!=*stu[i].num)
{
if(i==N-1)
printf("\n查无此学号!\n");
}
else*/

{
printf("\n修改过后原有数据将消失,确定?(y/n)");
scanf("%c",&f);
if(f=='y')
{
for(i=0;i<N;i++)
{
if(n==*stu[i].num)
{
do
{
printf("\n 【数据修改】\n");
printf("\n1.学号 2.姓名 3.性别 4.班级 5.成绩 6.退出修改\n");
printf("\n重新选择输入该学生数据,用命令前的数字表示:");
scanf("%d",&e);
switch(e)
{
case 1 : printf("\n学号:");scanf("%d",stu[i].num);break;
case 2 : printf("\n姓名:");scanf("%s",stu[i].name);break;
case 3 : printf("\n性别,男(女)性用b(g)表示:");scanf("%s",stu[i].sex);break;
case 4 : printf("\n班级:");scanf("%s",stu[i].cla);break;
case 5 : for(j=0;j<3;j++)
{
printf("\nscore %d:",j+1);
scanf("%d",&stu[i].score[j]);
}break;
}
}
while(e!=6);
printf(" \n修改完成!\n");
}
}
}
printf("\n修改结束!\n");
}
}

void cl(struct sudent stu[])
{
void px();
void cx();
void tj();
int q;
do
{
printf("\n 【数据处理】\n");
printf("\n 1.排序 2.查询 3.统计 4.返回上层\n");
printf("\n请输入您要执行的命令,用命令前的数字表示:");
scanf("%d",&q);
switch(q)
{
case 1 : px(stu);break;
case 2 : cx(stu);break;
case 3 : tj(stu);break;
}
}
while(q!=4);
}

void px()
{
int l,k,i,j;
for(l=0;l<N;l++)
stu[N+l]=stu[l];
for(l=0;l<N-1;l++)
for(k=0;k<N-l-1;k++)
if(*stu[k+N].num>*stu[N+k+1].num)
{
stu[N+N]=stu[N+k];stu[N+k]=stu[N+1+k];stu[N+1+k]=stu[N+N];
}
printf("\n学号 姓名 性别 班级 score1 score2 score3\n");
for(i=N;i<N+N;i++)
{
printf("%-15d%-15s%-10s%-10s",*stu[i].num,stu[i].name,stu[i].sex,stu[i].cla);
for(j=0;j<3;j++)
printf("%-9d",stu[i].score[j]);
printf("\n");
}
printf("\n 排序完成!\n");
}

void cx()
{
int n,i,j;
printf("\n请输入您要查询的学生学号:");
scanf("%d",&n);
for(i=0;i<N;i++)
if(n!=*stu[i].num)
{
if(i==N-1)
printf("\n查无此学号!");
}
else
{
printf("\n学号 姓名 性别 班级 score1 score2 score3\n");
printf("%-15d%-15s%-10s%-10s",*stu[i].num,stu[i].name,stu[i].sex,stu[i].cla);
for(j=0;j<3;j++)
printf("%-9d",stu[i].score[j]);
printf("\n");
}
}

void tj()
{
void pjf();
void loss();
int t;
do
{
printf("\n 【统计】\n");
printf("\n1.输出各学生的平均分 2.存在不及格科目的学生 3.返回上层\n");
printf("\n请输入您要执行的命令,用命令前的数字表示:");
scanf("%d",&t);
switch(t)
{
case 1 : pjf();break;
case 2 : loss();break;
}
}
while(t!=3);
}

void pjf()
{

}

void loss()
{

}

Ⅹ 学生管理系统的介绍

学生信息管理系统是针对学校学生处的大量业务处理工作而开发的管理软件,主要用于学校学生信息管理,总体任务是实现学生信息关系的系统化、科学化、规范化和自动化,其主要任务是用计算机对学生各种信息进行日常管理,如查询、修改、增加、删除等,另外还考虑到学生选课,针对这些要求设计了学生信息管理系统。推行学校信息管理系统的应用是进一步推进学生学籍管理规范化、电子化、控制辍学和提高义务教育水平的重要举措。

阅读全文

与学生管理系统的电脑版相关的资料

热点内容
电脑有哪些方法装系统 浏览:751
机器学习gpu电脑配置 浏览:136
电脑启动黑屏一下又好了 浏览:1000
只是电脑找不到光猫wifi 浏览:222
电脑键盘怎么打开 浏览:35
电脑安装剪影显示未安装显卡驱动 浏览:379
win7电脑字体模糊 浏览:416
电脑连wifi的时候能开热点吗 浏览:699
清理手机垃圾软件苹果 浏览:971
老旧电脑怎么重新装系统xp 浏览:288
加密电脑文件夹哪个好用 浏览:951
电脑桌面布局软件 浏览:46
区域网电脑文件互传 浏览:224
电脑安装了新内存条怎么测速 浏览:316
上门组装电脑哪个软件靠谱 浏览:344
几百兆cad电脑配置 浏览:565
独立显卡平板电脑 浏览:596
双路电脑cpu一个月多少电费 浏览:553
电脑哪个看图软件是直接看图 浏览:177
帕杰罗电脑板在哪里 浏览:141