学生管理app源码_学生管控app

hacker|
66

文章目录:

学生宿舍管理 (一)、内容: 请用C语言为宿舍管理人员编写一个宿舍管理软件.

基本上就是这样了。。。只有输出输入用了c++的cout/cin你可以自己换成printf和scanf,很简单的。。

程序在vc下运行了。

#includeiostream.h

#includestring.h

#includestdio.h

#includestdlib.h

struct student{

char ID[10];//学号

int BN;//床号

char RN[10];//宿舍号

char NAME[10];//姓名

student *next;

};

typedef student stu;

stu* Head;

int menu()//用户选择的菜单

{

cout"1:查看学生信息"endl;

cout"2按学号排序:"endl;

cout"3:查看宿舍的人员信息"endl;

cout"0:退出系统"endl;

cout"请选择"":";

char c;

int ch;

int flag=1;

while(flag)

{

cinc;

ch=(int)c-48;

if(ch=0ch=3)

flag=0;

else

cout"输入错误,请重新输入:";

}

return ch;

}

void sort(stu *head)//冒泡排序

{ int time=0;

char id[10];

int bn;

char rn[10];

char name[10];

stu* temp=head;

while(temp-next!=NULL)

{

temp=temp-next;

time++;

}

temp=head;

int i,j,last;

i=time-1;while(i0){

for(j=0;ji;j++)

{

if(temp-BNtemp-next-BN)

{

strcpy(id,temp-ID);

strcpy(rn,temp-RN);

strcpy(name,temp-NAME);

bn=temp-BN;

strcpy(temp-ID,temp-next-ID);

strcpy(temp-RN,temp-next-RN);

strcpy(temp-NAME,temp-next-NAME);

temp-BN=temp-next-BN;

strcpy(temp-next-ID,temp-ID);

strcpy(temp-next-RN,temp-RN);

strcpy(temp-next-NAME,temp-NAME);

temp-next-BN=temp-BN;

last=j;

}

i=last;

}

}

cout"排序成功!!!"endl;

}

void List(stu *head) // 打印所有学生信息

{

stu *p;

p=head;

if(p==NULL)

cout"记录为空"endl;

else

{ cout"记录如下:"endl;

while(p!=NULL){

coutp-ID" "p-BN" "p-RN" "p-NAMEendl;

p=p-next;

}

}

}

stu *InputNewRecord(stu *node)//输入新加成员的信息

{

cout"Input ID\n";

cinnode-ID;

cout"Input BN\n";

cinnode-BN;

cout"Input RN\n";

cinnode-RN;

cout"Input NAME\n";

cinnode-NAME;

return node;

}

int OkOrNot(char *name)

{

char c;

cout"请确认想进行此项操作(是请按y或者Y)";

cinc;

if(c=='y'||c=='Y')

return 1;

else

return 0;

}

void AppendNode(stu *head)/*在链表的末尾添加新的节点*/

{

stu *p,*newnode,*last;

if(!OkOrNot("Append")) return;

last=head;

p=head-next;

while(p!=NULL)

{

last=p;

p=p-next;

}

newnode=(stu*)malloc(sizeof(stu));

newnode-next=NULL;

p=InputNewRecord(newnode);

last-next=p;

}

void ShowRD(stu *head)//查找某宿舍的学生信息

{

stu *p=head;

int flag=1;

cout"输入你要查看的房间号:"endl;

char tp[10];

gets(tp);

for(;p!=NULL;p=p-next)

{

if(strcmp(p-RN,tp)==0)//找到并打印

{

coutp-ID"**"p-BN"**"p-RN"**"p-NAMEendl;

flag=0;

}

}

if(flag)

}

int main()

{

stu a=;

stu *head;

head=a;

head-next=NULL;

Head=head;

cout" 欢迎进入宿舍信息管理系统 "endl;

cout" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ "endl;

begin: AppendNode( Head);

cout"还要输吗?"endl;

char k;

cink;

if(k=='Y'||k=='y')

goto begin;

int f3=1;

while(f3)

{

switch(menu())

{

case 1:

List(Head);

break;

case 2:

sort(Head);

break;

case 3:

ShowRD(Head);

break;

case 0:

f3=0;

break;

}

}

return 0;

}

一个App系统的全套源代码包括那些?

本人觉得

一个完整的java源程序应该包括下列部分:

package语句; //该部分至多只有一句,必须放在源程序的第一句

import语句; /*该部分可以有若干import语句或者没有,必须放在所有的 类定义之前*/

public classDefinition; //公共类定义部分,至多只有一个公共类的定义 //java语言规定该java源程序的文件名必须与该公共类名完全一致 classDefinition; //类定义部分,可以有0个或者多个类定义

interfaceDefinition; //接口定义部分,可以有0个或者多个接口定义 例如一个java源程序可以是如下结构,该源程序命名为HelloWorldApp.java: package javawork.helloworld; /*把编译生成的所有.class文件放到包 javawork.helloworld中*/ import java.awt.*; //告诉编译器本程序中用到系统的AWT包 import javawork.newcentury; /*告诉编译器本程序中用到用户自定义 的包javawork.newcentury*/

public class HelloWorldApp{......} /*公共类HelloWorldApp的定义, 名字与文件名相同*/ class TheFirstClass{......} //第一个普通类TheFirstClass的定义 class TheSecondClass{......} //第二个普通类TheSecondClass的定义 ...... //其它普通类的定义 interface TheFirstInterface{......} /*第一个接口

TheFirstInterface的定义*/ ...... //其它接口定义

请问大家有没有QT做的一些小型的软件源码(涉及到表格的最好!),比如学籍管理软件,信息管理系统等等////

Qt自带的demo就很好,各个方面都有介绍到,源码也很清晰,有什么不会的就先看看demo里有没有例子吧。

这个是一个开源网站,嗯,应该有些有用的东西。。

java学生管理系统源码用什么软件打开

源码本身也是文本文件,可以直接用记事本打开,也可以将项目导入到eclipse或

myeclipse

去看,如果是编译后的.

class文件

,可以去网上找找查看.class文件的工具。

4条大神的评论

  • avatar
    访客 2022-07-05 上午 02:38:37

    的.class文件,可以去网上找找查看.class文件的工具。

  • avatar
    访客 2022-07-05 上午 01:04:03

    名字与文件名相同*/ class TheFirstClass{......} //第一个普通类TheFirstClass的定义 class TheSecondClass{......} //第二个

  • avatar
    访客 2022-07-04 下午 05:22:06

    -next; } }} stu *InputNewRecord(stu *node)//输入新加成员的信息 {cout"Input ID\n"; cinnode-ID; co

  • avatar
    访客 2022-07-05 上午 04:14:07

    ;int menu()//用户选择的菜单{ cout"1:查看学生信息"endl; cout"2按学号排序:"endl; cout"3:查看宿舍的人员信息"endl; cout"0:退出系统"endl; cout"请选择"":"; char c; int ch; int flag=1; wh

发表评论