hey this is a code written by one of my friend.It has a lot of errors and i am yet to debug them..however there is one type of error that i do not understand.
when compiled in Code::Blocks the error shows ""cout" does not name a type" in some places while other "cout"s work fine.....whay is this happening...
also this happens with cin ..
i have compiled other programs in the Code::Bolcks using the same settings and compiler but they all compiled fine...
public:
int pnr,tno;
char tname[30];
char bp[20],dest[20];
char pname[100][100];
int age[20];
char clas[100];
int nosr,i,d,m,y,con;
float amc;
void getresdet();
cout<<"Enter class";
cout<<endl<<"f for first class"<<endl<<"s for second class";
gets(clas);
cout<<"date of travel";
cin>>d>>m>>y;
cout<<"\n\nenter concessions from below\n";
cout<<"1.Military \n2.Senior citizen\n";
cout<<"3.Children below 5 years\n4.none\n";
cout<<"Enter your choice:";
cin>>con;
};
YOu are trying to code inside class declaration. Move it to some function.