#include <iostream>
#include <conio.h>
#include <time.h>
using namespace std;
main()
{
char name[25],address[50];
int inmonth,inday,room,outmonth,outday,contactno;
string user,pass;
for(int atmp=0;atmp >-3;atmp--){
cout<<"Attempt(s): "<<atmp+3<<endl<<endl;
cout<<"Username: ";
cin>>user;
cout<<"Password: ";
cin>>pass;
if((user == "group2")||(pass=="adminpass")){
break;
}
else{
cout<<"Wrong Password"<<endl<<endl;
}
if(atmp == -2){
cout<<"Exiting Program.... To many attempts";
getch();
return 0;
}
}
system("cls");
cout<<"\t\tLogin Approved!!!!"<<endl<<endl;
cout<<" Hotel Reservation \n\n";
cout<<"Please Enter Costumer Name: ";
cin.getline(name,sizeof(name));
cin.getline(name,sizeof(name));
cout<<"Full Address; ";
cin.getline(address,sizeof(address));
cout<<"Contact no.; ";
cin>>contactno;
system("cls");
cout<<"\n1 = January \t| 2 = February \t| 3 = March \t| 4 = April\n";
cout<<"5 = May \t| 6 = June \t| 7 = July \t| 8 = August\n";
cout<<"9 = September \t| 10 = October \t| 11 = November\t| 12 = December\n";
cout<<"Enter The (no.)Month of Reservation: ";
cin>>month;
if ((month>=13)||(month<=0)){
cout<<"\n\n\t\t\tInvalid Input";
getch();
return 0;
}
system("cls");
if ((month == 1)||(month == 3)||(month == 5)||(month == 7)||(month == 8)||(month == 10)||(month == 11)){
cout<<"Enter Day (1-31): ";
cin>>day;
if ((day<=0)||(day>=32)){
cout<<"Invalid Input";
getch();
return 0;
}
}
else if (month == 2){
cout<<"Enter Day (1-28/29): ";
cin>>day;
if ((day<=0)||(day>=30)){
cout<<"Invalid Input";
getch();
return 0;
}
}
else
{
cout<<"Enter Day (1-30): ";
cin>>day;
if ((day<=0)||(day>=31)){
cout<<"Invalid Input";
getch();
return 0;
}
}
system("cls");
cout<<"1 = Class S \t| 2 = Class A \t| 3 = Class B\t|";
cout<<"\nRoom Class[no]: ";
cin>>room;
//if (room==1){
system("cls");
cout<<"Cos
getch();
return 0;
}