1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176
|
#include<iostream>
#include<cctype>
#include<iomanip>
#include<cstdlib>
#include<string.h>
using namespace std;
int main()
{
char seats[5];
int m,i;
struct seat
{
wchar_t seat1,seat2,seat3,seat4,seat5,seat6,seat7,seat8,seat9,seat10
,seat11,seat12,seat13,seat14,seat15,seat16,seat17,seat18,seat19,
seat20,seat21,seat22,seat23,seat24,seat25,seat26,seat27,seat28,
seat29,seat30,seat31,seat32,seat33,seat34,seat35,seat36,seat37,
seat38,seat39,seat40,seat41,seat42,seat43,seat44,seat45,seat46,seat47,seat48,seat49,seat50,
seat51,seat52,seat53,seat54,seat55,seat56,seat57,seat58,seat59,seat60,seat61,seat62,seat63,
seat64,seat65,seat66,seat67,seat68,seat69,seat70,seat71,seat72,seat73,seat74,seat75,seat76,
seat77,seat78,seat79,seat80,seat81,seat82,seat83,seat84;
};
seat num;
num.seat1=1;
num.seat2=2;
num.seat3=3;
num.seat4=4;
num.seat5=5;
num.seat6=6;
num.seat7=1;
num.seat8=2;
num.seat9=3;
num.seat10=4;
num.seat11=5;
num.seat12=6;
num.seat13=1;
num.seat14=2;
num.seat15=3;
num.seat16=4;
num.seat17=5;
num.seat18=6;
num.seat19=1;
num.seat20=2;
num.seat21=3;
num.seat22=4;
num.seat23=5;
num.seat24=6;
num.seat25=1;
num.seat26=2;
num.seat27=3;
num.seat28=4;
num.seat29=5;
num.seat30=6;
num.seat31=1;
num.seat32=2;
num.seat33=3;
num.seat34=4;
num.seat35=5;
num.seat36=6;
num.seat37=1;
num.seat38=2;
num.seat39=3;
num.seat40=4;
num.seat41=5;
num.seat42=6;
num.seat43=1;
num.seat44=2;
num.seat45=3;
num.seat46=4;
num.seat47=5;
num.seat48=6;
num.seat49=1;
num.seat50=2;
num.seat51=3;
num.seat52=4;
num.seat53=5;
num.seat54=6;
num.seat55=1;
num.seat56=2;
num.seat57=3;
num.seat58=4;
num.seat59=5;
num.seat60=6;
num.seat61=1;
num.seat62=2;
num.seat63=3;
num.seat64=4;
num.seat65=5;
num.seat66=6;
num.seat67=1;
num.seat68=2;
num.seat69=3;
num.seat70=4;
num.seat71=5;
num.seat72=6;
num.seat73=1;
num.seat74=2;
num.seat75=3;
num.seat76=4;
num.seat77=5;
num.seat78=6;
num.seat79=1;
num.seat80=2;
num.seat81=3;
num.seat82=4;
num.seat83=5;
num.seat84=6;
cout << " --------------------------------"<<endl;
cout << " \t~C O C K P I T~\t\t"<<endl;
cout << " --------------------------------"<<endl;
cout << "A:_"<<num.seat1<<"_::_"<<num.seat2<<"_::_"<<num.seat3<<"_:: ::_"<<num.seat4<<"_::_"<<num.seat5<<"_::_"<<num.seat6<<"_:"<<endl;
cout << "B:_"<<num.seat7<<"_::_"<<num.seat8<<"_::_"<<num.seat9<<"_:: ::_"<<num.seat10<<"_::_"<<num.seat11<<"_::_"<<num.seat12<<"_:"<<endl;
cout << "C:_"<<num.seat13<<"_::_"<<num.seat14<<"_::_"<<num.seat15<<"_:: ::_"<<num.seat16<<"_::_"<<num.seat17<<"_::_"<<num.seat18<<"_:"<<endl;
cout << "D:_"<<num.seat19<<"_::_"<<num.seat20<<"_::_"<<num.seat21<<"_:: ::_"<<num.seat22<<"_::_"<<num.seat23<<"_::_"<<num.seat24<<"_:"<<endl;
cout << "E:_"<<num.seat25<<"_::_"<<num.seat26<<"_::_"<<num.seat27<<"_:: ::_"<<num.seat28<<"_::_"<<num.seat29<<"_::_"<<num.seat30<<"_:"<<endl;
cout << "F:_"<<num.seat31<<"_::_"<<num.seat32<<"_::_"<<num.seat33<<"_:: ::_"<<num.seat34<<"_::_"<<num.seat35<<"_::_"<<num.seat36<<"_:"<<endl;
cout << " : :"<<endl;
cout << "G:_"<<num.seat37<<"_::_"<<num.seat38<<"_::_"<<num.seat39<<"_:: ::_"<<num.seat40<<"_::_"<<num.seat41<<"_::_"<<num.seat42<<"_:"<<endl;
cout << "H:_"<<num.seat43<<"_::_"<<num.seat44<<"_::_"<<num.seat45<<"_:: ::_"<<num.seat46<<"_::_"<<num.seat47<<"_::_"<<num.seat48<<"_:"<<endl;
cout << "I:_"<<num.seat49<<"_::_"<<num.seat50<<"_::_"<<num.seat51<<"_:: ::_"<<num.seat52<<"_::_"<<num.seat53<<"_::_"<<num.seat54<<"_:"<<endl;
cout << "J:_"<<num.seat55<<"_::_"<<num.seat56<<"_::_"<<num.seat57<<"_:: ::_"<<num.seat58<<"_::_"<<num.seat59<<"_::_"<<num.seat60<<"_:"<<endl;
cout << "K:_"<<num.seat61<<"_::_"<<num.seat62<<"_::_"<<num.seat63<<"_:: ::_"<<num.seat64<<"_::_"<<num.seat65<<"_::_"<<num.seat66<<"_:"<<endl;
cout << "L:_"<<num.seat67<<"_::_"<<num.seat68<<"_::_"<<num.seat69<<"_:: ::_"<<num.seat70<<"_::_"<<num.seat71<<"_::_"<<num.seat72<<"_:"<<endl;
cout << "M:_"<<num.seat73<<"_::_"<<num.seat74<<"_::_"<<num.seat75<<"_:: ::_"<<num.seat76<<"_::_"<<num.seat77<<"_::_"<<num.seat78<<"_:"<<endl;
cout << "N:_"<<num.seat79<<"_::_"<<num.seat80<<"_::_"<<num.seat81<<"_:: ::_"<<num.seat82<<"_::_"<<num.seat83<<"_::_"<<num.seat84<<"_:"<<endl;
cout << "Enter Your Seat Choice:";
cin >> seats;
cout << endl;
for(int i=0 ; i<100 ; i++)
{
seats[i] = toupper(seats[i]);
}
if(seats!='\0')
{
m=strcmp("A1",seats);
if(m==0)
{
num.seat1='X';
}
}
if(seats=='A1')
{
num.seat1='X';
}
cout << num.seat1;
system("pause");
return 0;
}
|