辽宁师范大学
    设计题目:火车订票系统设计
专业:        电子信息工程             
    班级:            09级3班             
    ****          ***********************
    学号:      **************              男孩名字大全2012
  总体设计斗鱼雅蒂(包含几大功能模块)    1
二 详细设计(各功能模块的具体实现算法——流程图)        2
三  调试分析(包含各模块的测试用例,及测试结果)    3
3.1源程序    6田梓呈
3.2调试与测试    31
总结    苹果4怎么下载歌曲33
  总体设计(包含几大功能模块)
1.Insert a train information(插入火车信息)
2.inquire a train jinformation(查询火车信息)
3.Book a train ticket(订票)
4.Update the train information(更新火车信息)
5.Advice to you about the train (建议)
葱爆海参的做法6.Save information to file(储存信息归档)
7.Quit the system(退出系统)
二、详细设计(各功能模块的具体实现算法——流程图)
2.1各函数的功能和实现
 
1.Insert a train information(插入火车信息):输入包括火车班次,最终目地,始发站,火车到站时间,车票价格,所定票号。可用函数void input来实现此操作
2.inquire a train jinformation(查询火车信息):没有任何记录
3.Book a train ticket(订票):输入你想要去的城市
4.Update the train information(更新火车信息):可用void find()来实现
5.Advice to you about the train (关于火车对你的建议)
6.Save information to file(储存信息归档)
7.Quit the system(退出系统):可用一个函数exit()来实现,首先将信息保存到文件中,释放动态创建的内存空间,再退出此程序。
流程图     
                                                       
详见A4纸上手绘
三  调试分析(包含各模块的测试用例,及测试结果)
3.1源程序
#include <conio.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int shoudsave=0 ;
int count1=0,count2=0,mark=0,mark1=0 ;
sm是什么啥意思/*定义存储火车信息的结构体*/
struct train
{
    char num[10];/*列车号*/
    char city[10];/*目的城市*/
    char takeoffTime[10];/*发车时间*/
    char receiveTime[10];/*到达时间*/
    int  price;/*票价*/
    int  bookNum ;/*票数*/
};
/*订票人的信息*/
struct man
{
    char num[10];/*ID*/
    char name[10];/*姓名*/
    int  bookNum ;/*需求的票数*/
};
/*定义火车信息链表的结点结构*/
typedef struct node
{
    struct train data ;
    struct node * next ;
}Node,*Link ;
/*定义订票人链表的结点结构*/
typedef struct people
{
    struct man data ;
    struct people*next ;