Question

In: Computer Science

This is a hotel room and guest management system, the main purpose of this procedure is to manage the room

 IN C.

This is a hotel room and guest management system, the main purpose of this procedure is to manage the room, manage the guest account and check the hotel performance (how many rooms are booked, etc.). There are two types of people who use this system, the manager and the receptionist.

As a manager, there are three options:

  1. Set/adjust room levels and rates for each level

Detail: there are 80 rooms in the hotel, 10 on each floor, eight floors. All rooms have four levels: **, ***, *** and VIP. I think the operation here is that the manager can manually input a room number, and then divide it into one of the four levels. Each level has a fixed price.

2. Manage customer information (add/adjust/delete)

Detail:The manager will be able to see a library of users and (add/remove/modify) the customer in it, as well as label some users with special VIP codes that will allow them to stay in VIP rooms.

3. Check hotel status

Detail: this means that the manager can see how many people have stayed in the hotel, if the most simplified, is the room occupancy rate.


Solutions

Expert Solution

SOURCE CODE

#include
void add();//this function for booking new room
void del();//this function for deleting the room
void modify();//this function is to adjust the customers in a room
int a[90];//this array for storing the information of all room
int n;//this is for storing the room number entered by the manager
int main()
{
int m;//this for storing selected one option from the menu
int i;
int z;
int s=0;//this for storing the total number of customers in the hotel
while(1){
printf("\nSelect one option\n1.add(for adding new room)\n2.remove(for removing the room )\n3.modify(adjust the memebrs in the room)\n4.exit");
scanf("%d",&m);
   if(m==4)//if we wanted to exit
        break;//loop will terminate

printf("\n Enter room number the room number is in the range of 0-79 ");
scanf("%d",&n);
//-------------------------------------------
//this is for giving the level of the room
z=n%4;
printf("\n The level of the room is %d",z);
if(z==4)
    printf("\n The level of the room is VIP");
//------------------------------------------------

    if(m==1)
        add();//calling add function
    else if(m==2)
        del();//calling the del function
    else if(m==3)
        modify();//calling the modify function
  
}
for(i=0;i<80;i++)
{
   if(a[i]!=0)//the allocated rooms only enter into inside
       {
           printf("\nroom %d:customers %d",i,a[i]);//printing the customers in each allocated room
           s=s+a[i];
          }      
}
printf("\nthe totla customers in hotel %d",s);//printing totol customers
  
return 0;
}
void add()
{
    int d;
    if(a[n]==0)
       { printf("\nEnter number of customers ");
        scanf("%d",&d);
        a[n]=d;//adding the customers to the room
       }
    else
        printf("\nThe room is already allocated");
}
void del()
{
    if(a[n]==0)
        printf("\nThe room is already empty");
    else
    {
        a[n]=0;//removing the customers from the room and room is making empty
  
        printf("\nthe room is removed");
    }  
}
void modify()
{
    int e,d;
    printf("\n1.add the memebrs to the room \n2.remove the memebrs from the room");
    scanf("%d",&e);
    if(a[n]==0)//if room is empty we can't modify the customers
        printf("\nThe room is already empty");
    else{
        printf("\n Enter the number of customers");
        scanf("%d",&d);
    if(e==1){//for adding members into the allocated room      
        a[n]=a[n]+d;
        printf("\n %d new customers added to the room %d",d,n);
        }
    else if(e==2){//removing members from the allocated room
      
        a[n]=a[n]-d;//subracting the customers from the already existing customers
        if(a[n]>0)
        printf("\n %d customers are removed from room %d",d,n);
        else
            printf("\n Invalid customers number");
      
    }
    else
  
        printf("\nselect valid option");
  
}
  
}

OUTPUT


Related Solutions

PROBLEM In the Hotel management domain, we have the following concepts: Hotel Hotel chain Hotel room  ...
PROBLEM In the Hotel management domain, we have the following concepts: Hotel Hotel chain Hotel room       Reservation Hilton Hilton San Diego Bayfront Meeting room Ballroom Guest Room Catering Service Internet Service       TV Service Guest Parking Service       Item on bill       You are asked to design a model, using a UML class diagram to relate the abovementioned concepts: Correctly use UML notations for relations such as generalization, association, aggregation, composition. Be careful to distinguish objects from classes. You...
The manager of a resort hotel stated that the mean guest bill for a weekend is...
The manager of a resort hotel stated that the mean guest bill for a weekend is $600 or less. A member of the hotel's accounting staff noticed that the total charges for guest bills have been increasing in recent months. The accountant will use a sample of future weekend guest bills to test the manager's claim. (a) Which form of the hypotheses should be used to test the manager's claim? Explain. H0: μ ≥ 600 Ha: μ < 600 H0:...
A hotel wanted to develop a new system for delivering room service breakfasts. In the current...
A hotel wanted to develop a new system for delivering room service breakfasts. In the current system, an order form is left on the bed in each room. If the customer wishes to receive a room service breakfast, he or she places the order form on the doorknob before 11p.m. The current system requires customers to select a 15-minute interval for desired delivery time (6:30~6:45a.m., 6:45~7:00a.m., etc.). The new system is designed to allow the customer to request a specific...
You are the revenue manager of a 200-room hotel in Memphis. The management controllable costs (variable...
You are the revenue manager of a 200-room hotel in Memphis. The management controllable costs (variable room costs) incurred when selling 1 room are $50. You are interested in evaluating hotel performance for two scenarios: fixed pricing and differential pricing. Scenario one is that you used a fixed pricing strategy: at a selling pricing $200 per night your hotel would sell 150 rooms on a given day. Scenario two is that you implement a three-price strategy: low rate $150 per...
Georges Hotel has the following sales procedures: The hotel uses duplicated and pre-numbered guest checks to...
Georges Hotel has the following sales procedures: The hotel uses duplicated and pre-numbered guest checks to record customers’ orders; the manager is in charge of monitoring the guest checks. She stores them in a storage container which is kept locked until she is ready to issue them to the servers. At the beginning of each shift, the manager issues the guest checks to the servers and records the amount given to each person on a blank sheet of paper. The...
The manager of the Hilton Resort Hotel stated that the mean guest bill for a weekend...
The manager of the Hilton Resort Hotel stated that the mean guest bill for a weekend is $600 or less. A member of the hotel’s accounting staff noticed that the total charges for guest bills have been increasing in recent months. The accountant will use a sample of future weekend guest bills to test the manager’s claim. a. Which form of the hypotheses should be used to test the manager’s claim? b. What conclusion is appropriate when ?0 cannot be...
1. The managers of the Ada Hotel forecast the breakfast covers based on number of guest...
1. The managers of the Ada Hotel forecast the breakfast covers based on number of guest rooms. Following table presents the number of rooms sold and breakfast covers for the past year, 2017. Room Guests Breakfast Covers January 1,200 1,400 February 1,020 1,220 March 1,250 1,420 April 1,100 1,320 May 1,380 1,520 June 1,400 1,580 July 1,520 1,650 August 1,550 1,690 September 1,450 1,400 October 1,210 1,380 November 1,080 1,240 December 1,050 1,220 Required: 1. Determine the coefficient of correlation...
Breakdown how Crave interactive can benfits hotel and boost guest experience.
Breakdown how Crave interactive can benfits hotel and boost guest experience.
The management of 50-room Gordion Hotel, which has single and double rooms only, has acquired the...
The management of 50-room Gordion Hotel, which has single and double rooms only, has acquired the following internal financial data: • Occupancy of 65.00% • Projected after-tax average daily room rate (ADR) of $54.00 • 25.00% of double room occupancy • A price difference of $15.00 more for double rooms than the singles Based on the financial information given, calculate the individual ADRs for single and double rooms for Gordion. The operation team of H hotel, which has 25 rooms...
Build a conceptional model for a Hotel Management System. The solution should be presented as an...
Build a conceptional model for a Hotel Management System. The solution should be presented as an ER-diagram. Base your design on the following requirements. • The database should record information about Customer, Hotel, Booking, Rooms, Employee, Feedback, and Payments. • A Customer has a name which consists of firstName, middleName and lastName. Customers are identified by a unique customerID. A Customer has an Address, phoneNo and email address – Customers can place any number of Bookings (including none). Customer may...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT