error C2061: syntax error : identifier 'Inputdata'
c 语言错误!!!
#include <stdio.h>
#include <string.h>
#include <conio.h>
//宏定义
#define MaxSpace 100
#define keylen 6
#define RADIX_n 10
#define RADIX_C 26
#define SHOW_MSG_ERROR "\n错误信息:航班号须由2位大写字母和4位数字组成。\n输出数据错误,程序终止执行!\n"
typedef char KeyType;
typedef struct
{//航班记录结构描述
char start[6];//起始站
char end[6];//终点站
char sche[6];//班期
char time1[6];//起飞时间
char time2[6];//到达时间
char model[3];//机型
int price;//票价
}InfoType;
typedef struct
{//关键字-静态链表结点类型
KeyType keys[keylen];//关键字(航班号)
InfoType others;
int next;
}SLNode;
typedef struct
{//关键字序列-静态链表类型
SLNode s1[MaxSpace];//静态链表
int keynum;//关键字字符数
int length;//表长
}SLList;
typedef int ArrType_n[RADIX_n];//数字字符
typedef int ArrType_c[RADIX_C];//字母字符
KeyType key[keylen], kl[4];
//13.输入航班记录函数
bool InputData(SLList &L){
int i;
i = ++L.length;
char yn = 'y';
printf ("\n请依次录入航班信息数据(航班号由2位大写字母和4位数字组成):");
do
{
printf ("\n航班号 起点站 终点站 航班期 起飞时间 到达时间 机型 票价\n");
scanf ("%s%s%s%s%s%s%s%d", L.s1[i].keys, L.s1[i].others.start, L.s1[i].others.end,
L.s1[i].others.sche, L.s1[i].others.time1, L.s1[i].others.time2, L.s1[i].others.model, &L.s1[i].others.price);
fflush (stdin);//清空输入缓冲区
if (!Check_HangBanHao (L.s1[i].keys))
{
return false;
}//endif
++i;
printf ("继续输入吗?y/n:");
}//enddo
while ( (yn = getche() == 'y') || yn == 'Y')
printf("\n");
L.length = i-1;
RadixSort(L);
Arrange(L);
return true;
}
//15.主函数
void main()
{
SLList L;
L.keynum = 6;
L.length = 0;//初始化
Prompt();//显示主菜单
if (!InputData (&L))
{
printf (SHOW_MSG_ERROR);
}
searchcon (L);//执行相关查询
}
:\Documents and Settings\jy\桌面\wwc航班信息查询与检索系统.c(196) : error C2061: syntax error : identifier 'Inputdata'
C:\Documents and Settings\jy\桌面\wwc航班信息查询与检索系统.c(196) : error C2059: syntax error : ';'
C:\Documents and Settings\jy\桌面\wwc航班信息查询与检索系统.c(196) : error C2059: syntax error : 'type'
#include <stdio.h>
#include <string.h>
#include <conio.h>
//宏定义
#define MaxSpace 100
#define keylen 6
#define RADIX_n 10
#define RADIX_C 26
#define SHOW_MSG_ERROR "\n错误信息:航班号须由2位大写字母和4位数字组成。\n输出数据错误,程序终止执行!\n"
typedef char KeyType;
typedef struct
{//航班记录结构描述
char start[6];//起始站
char end[6];//终点站
char sche[6];//班期
char time1[6];//起飞时间
char time2[6];//到达时间
char model[3];//机型
int price;//票价
}InfoType;
typedef struct
{//关键字-静态链表结点类型
KeyType keys[keylen];//关键字(航班号)
InfoType others;
int next;
}SLNode;
typedef struct
{//关键字序列-静态链表类型
SLNode s1[MaxSpace];//静态链表
int keynum;//关键字字符数
int length;//表长
}SLList;
typedef int ArrType_n[RADIX_n];//数字字符
typedef int ArrType_c[RADIX_C];//字母字符
KeyType key[keylen], kl[4];
//13.输入航班记录函数
bool InputData(SLList &L){
int i;
i = ++L.length;
char yn = 'y';
printf ("\n请依次录入航班信息数据(航班号由2位大写字母和4位数字组成):");
do
{
printf ("\n航班号 起点站 终点站 航班期 起飞时间 到达时间 机型 票价\n");
scanf ("%s%s%s%s%s%s%s%d", L.s1[i].keys, L.s1[i].others.start, L.s1[i].others.end,
L.s1[i].others.sche, L.s1[i].others.time1, L.s1[i].others.time2, L.s1[i].others.model, &L.s1[i].others.price);
fflush (stdin);//清空输入缓冲区
if (!Check_HangBanHao (L.s1[i].keys))
{
return false;
}//endif
++i;
printf ("继续输入吗?y/n:");
}//enddo
while ( (yn = getche() == 'y') || yn == 'Y')
printf("\n");
L.length = i-1;
RadixSort(L);
Arrange(L);
return true;
}
//15.主函数
void main()
{
SLList L;
L.keynum = 6;
L.length = 0;//初始化
Prompt();//显示主菜单
if (!InputData (&L))
{
printf (SHOW_MSG_ERROR);
}
searchcon (L);//执行相关查询
}
:\Documents and Settings\jy\桌面\wwc航班信息查询与检索系统.c(196) : error C2061: syntax error : identifier 'Inputdata'
C:\Documents and Settings\jy\桌面\wwc航班信息查询与检索系统.c(196) : error C2059: syntax error : ';'
C:\Documents and Settings\jy\桌面\wwc航班信息查询与检索系统.c(196) : error C2059: syntax error : 'type'
...全文
相关推荐
C语言命语法错误大全
C语言命语法错误大全
VC++调试错误代码.pdf
VC++调试错误代码.pdf
VS2010 C++学习(5):基于DirectShow视频预览录像文档
VS2010 C++学习(5):基于DirectShow视频预览录像程序文档
evc 转换到 vs2005的若干问题
描述了evc 到vs2005代码转换的一些问题, 方便vs2005下的嵌入式程序开发
MATLABSimulink模拟及会议论文,关于具备自动温度控制和能耗分析的智能太阳能热水系统。.zip
1.版本:matlab2014a/2019b/2024b 2.附赠案例数据可直接运行。 3.代码特点:参数化编程、参数可方便更改、代码编程思路清晰、注释明细。 4.适用对象:计算机,电子信息工程、数学等专业的大学生课程设计、期末大作业和毕业设计。


