writing c program for booking bus seats
The Let’s go bus company consists of one bus with a seatingcapacity of 12. The bus seating is arranged in 6 rows with 2 seatsper row. The program uses an array of 12 structures. Each structureholds a seat identification number, a marker that indicates whetherthe seat is assigned, the last name of the seat holder, and thefirst name of the seat holder.
The program displays the following menu: To choose a function,enter its letter label:
a. Display ALL 12 seats assignments (including Empty).
b. Show ONLY a list of empty seats and show total of emptyseats
c. SHOW ONLY the assigned seats with name of person and totalassigned.
d. Assign the customer to an empty seat.
e. Delete ONE seat assignment.
f. Delete ALL seat assignments.
q. Quit program.
We have to use switch case for selecting options above (just forselecting options a,b,c,d,e,f,q) and each select have to hasseparate functions. So asking option is main function
No pointer and using structure is required.
So let’s get started.. If I enter the input a then it will showme the list of 12 seats. Each seat contains seat status which isshowing empty or not and it’s also showing each seat’s ownersfirst, last name if the seat is empty just better put empty seat.After checking option a there should be something asking me do uwanna continue to menu then I come back to menu. I put the input dthen program ask me which seat I wanna put between 1 to 12 and Iput number, first name and last name and go back to menu So… it’slike that 🙂 I really appreciate for your effort thankyou
Answer to writing c program for booking bus seats Description: The Let’s go bus company consists of one bus with a seating capacit…