我编的一个课程设计的宾馆管理有错误麻烦帮忙看看
#include<iostream>#include<string>
using namespace std;
class room
public:
void select();
void shuchu();
void xiugai();
void chaxun();
void menu();
void tuichu();
void qingping();
private:
int num;string name;double price;string grade;checked;int capacity;
void list::menu()
{
cout<<"********* 宾馆信息管理系统******<<"endl;
cout<<"*****1:浏览"<<endl;
cout<<"*****2:增加数据"<<endl;
cout<<"*****3:查询数据"<<endl;
cout<<"*****4:修改数据"<<endl;
cout<<"*****5退出"<<endl;
}
void room::qingping()
{
cout<<"操作完毕:1返回菜单,2退出系统"<<endl;
cin>>m;
if(c==1){menu();break;}
if(c==2){tuichu();break;}
else cout<<"输入有误,请重新输入"<<endl;
}
void room::select()
{
menu();
cout<<"输入操作数"<<endl;
int n;
cin>>n;
switch(n)
{
case 1:shuchu();break;
case 2:luru();break;
case 3:chaxun();break;
case 4:xiugai();break;
case 5:tuichu();break;
default:{cout<<"您输入的信息有误,请重新输入"<<endl;
}
void room::luru()
{ char f;int i;
cout<<"请输入房间号 姓名 价格 是否入住 容量等信息"<<endl;
cout<<"如果想终止录入请在每条录入结束后输入小写字母n"<<endl;
for(i=0;i<30;i++)
{
cin<<room[i].num<<room[i].name<<room[i].price<<room[i].checkedroom[i].capacity<<f<<endl;
if(f==n)break;
}
qingping();
}
void list::shuchu()
{
int a;
for(a=0;a<30;a++)
{
cout<<"房间号"<<roomr[a].num<<"姓名"<<room[a].name<<"容量"<<room[a].capacity<<"等级"<<room[a].grade<<"入住情况"<<room[a].checked<<endl;
}
cout<<"输出完毕,请输入你想要的操作1:返回菜单,2:退出系统"<<endl;
{
int k;
cin>>k;
if(k==1){menu();break;}
if(k==2){tuichu();break;}
}
qinbgping();
}
void list::chaxun()
{
cout<<"请输入你要的查询方式1:房间号<<endl;
cout<<"
int l,num2,j,f,rongliang;
cin>>l;
switch(l)
{
case:1 cout<<"请输入房间号:"<<endl;
cin>>sri;
for(j=0;j<30;j++)
if(num==num2)break;
cout<<"房间号"<<room[j].num<<"姓名"<<room[j].name<<"容量"<<room[j].capacity<<"等级"<<room[j].grade<<"入住情况"<<room[j].checked<<"价格"<<room[j].price<<endl;
case:2 cout<<"请输入容量:"<<endl;
cin>>rongliang;
for(f=0;f<30;f++)
{
if(room[f].capacity==rongliang)break;
cout<<"房间号"<<roomr[i].num<<"姓名"<<room[i].name<<"容量"<<room[i].capacity<<"等级"<<room[i].grade<<"入住情况"<<room[i].checked<<endl;
}
}
qingpng();
}
void room::xiugai()
{
cout<<"请输入你要修改的数据的序号0-30"<<endl;
cin>>s;
cout<<"请重新输入房间号 姓名 容量 价格 等级 是否入住等信息"<<endl;
cin<<room[s].num<<room[s].name<<room[s].capacity<<room[s].price<<room[s].grade<<room[s].checked<<endl;
qingping();
}
void room::tuichu()
{
cout<<"欢迎使用本系统,再见"<<endl;
}
int main()
{
room xcy;
xcy.menu;
xcy.select
return o;
}