cout << "Enter your room type ('g' for garden view, 'p' for pool view, or 'l' for lake view: ";
cin.get();
room_type = cin.get();
cout << "Enter your number of day you stayed: ";
cin >> days;
cout << "Did you have a refrigerator (y/n): ";
cin.get();
frig = cin.get();
cout << "Did you have an extra bed (y/n): ";
cin.get();
bed = cin.get();
//Calculate and output the results
if (room_type = 'g')
rate = g-v * days;
if (room_type = 'p')
rate = p-v * days;
if (room_type = 'l')
rate = l-v * days;
if (frig = 'y')
frig = days * 2.5;
else
frig = 0;
if (bed = 'y')
bed = days * 15.00;
else
bed = 0;
gt = rate + frig + bed;
//output the results
cout << "The room type you stayed in was the: " << setw(14) << room_type << endl;
cout << "The number of days you stayed was: " << setw(14) << days << endl;
cout << "Your basic room rate was: " << setw(14) << rate << endl;
cout << "Your charge for a refrigerator was: " << setw(14) << frig << endl;
cout << "Your charge for an extra bed was: " << setw(14) << bed << endl;
cout << "Your total charge for the stay is: " << setw(14) << gt << endl;
In your variable declarations, you are using , instead of ;. It's saying that after the comma, it expects another variable name rather than another type name.
For example, you can:
1 2 3 4 5 6 7 8 9 10
// same type:
int a, b, c;
// different types:
int a;
double b;
constint c;
// or you could list same types the "long" way:
int a;
int b;
int c;