Hi Need a little help!! This is the usual manage the hotel program.
What I need to do:
REPORT 1 lists all the occupied rooms and which customer is in each room.
REPORT 2 lists all the empty rooms.
REPORT 3 lists all customers who are checked in and what room they are in.
REPORT 4 lists all customers whoa are not checked in.
REPORT 3 and 4 should be sorted by name.
REPORT 1 and 2 should be sorted by floor and by room.
I need help with the sorting part.Please give an example!!!
if((*ptrRoom).whoCheckedIn!=0)
{
return "Room is occupied\n";
}
if((*ptrCust).haveReservation!=0)
{
return "Customer is in the room\n";
}
(*ptrCust).whoCheckedIn=roomID;
(*ptrRoom).haveReservation=customerID;
return "Customer is Checked In\n";
}