A sample program execution is provided at the end of the document, to help you visualize...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
A sample program execution is provided at the end of the document, to help you visualize and understand what the program should do. You should use the same input as the sample program, for the screenshots that you submit with your assignment. The flight route is from Johannesburg to Cape Town with the travel duration fixed at 2 % hours. Departure and arrival locations remain the same. o Departure is always from Johannesburg and destination is aiways Cape Town. The departure and arrival times are: Option Departure Time Arrival Time 7:00 9:30 2 9:00 11:30 3 11:00 13:30 4 13:00 15:30 5 15:00 17:30 The seating arrangement is six seats in a row, three on the left side and three on the right side of the plane with a walkway (passage) in between. See the image of the setup below. (image source: http://travelgurureviews.com/kulula-com-reviews/airline-reviews/) o The total number of seats in the flight is 50. You are required to write a program that simulates a flight booking system. COS1511/103/1/2020 There are two classes of travel: First Class and Economy class. • The front four rows are considered as 'First Class' and all other rows to the back are 'Economy Class'. o The cost for economy class is fixed at R1 600.00. • The first class travel ticket is 20% more costly than the economy class. Questions You are required to do the following. (See the sample output screenshots for clarification). Write a program that will do the following: 1. Prompt (ask) the user to enter his/her full name. Welcome to Cos1511 Flight Booking system Enter full name Hannah George 2. Then display a menu showing the available times for the flight. The user can choose a preferred departure time (option 1 -5). The option selected should be validated for 1-5. Welcome to COs1511 Flight Booking system Enter full name Hannah George The available travel times for flights are: Depart 1. 2. 3. 11.00 Arrive 7.00 9.30 9.00 11.30 Validation for time option 13.30 15.30 17.30 chosen 4. 13.00 5. 15.00 Choose the time by entering the option numbe from the displayed list: Incorrect option! Please choose from 1-5. 3. If the user has entered a valid option, the seating arrangement for that particular flight time should be displayed to the user for the user to choose a seat. The available seats for 7.00 are as follows: First Class(1920.00) |A1|A2|A3|---- |A4|AS| A6| I81|B2|83|--- B4|B5| B6| |ci|c2|c3|- D1 D2 D3|---- D4|D5|D6İ Economy class(1600.00) |E1|E2|E3| -- IF1|F2İF3|- |G1|G2|G3|- H1|H2|H3|- i11|12| Please key in a seat number to choose a seat(eg:A2) A1 icajcsic6i TE4|ES|E6| İF4|FSİF6| |G4|G5|G6| If any seats have already been booked for that time, the booked seats should be indicated and displayed using "**". cOS 1511/103/1/2020 The user can then choose a suitable seat number that is available. The seat number should be validated to see if it has already been booked. In other words, if the user enters a seat number that is aiready booked, display a user-friendly message and give the option to enter the seat number again. The available seats for 7.00 are as follows: Flest Class(1920.00) Booked seats indicated with "*** BI[82|83| |c1]c2|c3] |D1|02|03| |Economy class(1600.00) |E1|E2|E3| |F1|F2|F3| IG1|G2|G3| H1|H2|H3| |84|B5|B6| (c4|c5|C6| |04 |D5|D6| |E4|ES|E6| ĮF4|FS|F6| ĮG4|GS|G6| |H4|H5 H6| Seats that are already taken are indicated with an asterisk Please key in a seat number to choose a seat(eg:A2) G3 4. Once the user has successfully chosen an available seat, a Flight booking ticket should be displayed on the screen. Check the sample screenshot for the details that need to be displayed on the ticket. Travel ticket for FLIGHT Name : Hannah George Travel Ticket class : First class : Al : 7,00 : 9.30 Seat No Departure Destination : Johannesburg Cape Town Departure Time Arrival Time ******* . Amount:R1920.00 Thank you for booking with cos1511. Your travel agent for queries is Annie Mathew ******* 5. The program should prompt (ask) the user if they would like to make additional bookings? Then the program should be able to repeat for more than one booking with various flight times. The check for 'y' or 'n' at the "Do you want to continue(Y/N)?" prompt should be case-insensitive. In other words, both Y' and 'y' should be accepted or both 'N' and 'n' should be accepted. Travel ticket for FLIGHT Name Hannah George Departure Destination 1 Johannesburg I Cape Town Travel Tieket class i First class Seat No Departure Time Arrival Time : Al : 7.00 I 0.30 Amount: R1920.00 Thank you for booking with cos1511. Your travel agent for queries is Annie Mathe Do you want to make another book Ing (Y/N)? Melcome to COSTSTI FaE Booking system Enter full name Deon Pieters The available travel tiimes for f1ights are: Depart 1. 7.00 2. 9.00 a. 11.00 4. 13.00 5. 15.00 Choose the time by entering the option number from the displayed list: Arrive 9.30 11. 30 13. 30 15. 30 17. 30 6. When the user has finished all the booking and chosen 'N' or 'n' at the "Do you want to continue(Y/N)?" prompt, the program should display the total number of bookings made for each flight time, just before exiting. mber of bookings made for 7.00 a.m:3 Number of bookings made for 9.00 a.m:0 Number of bookings made for 11.00 a.m:0 Number of bookings made for 13.00 p.m:0 Number of bookings made for 15.00 p.m:1 The program should display the total bookings for each time, before exiting. Process returned e (exe) Press any key to continue. execution time 125.236 s Submit the full program code and output screenshots. Include screenshots in your submission showing: the program repeating; input validations; booking for different flight times. You are required to define and use functions to do the following: Display the menu for flight times, accept the user option and validate the user option. • Call the function to validate the menu option from here. Validate the menu option for flight times. Display the seating arrangement (You might have to use two different functions for seat display). o ie. before any booking has been made, you have one seating arrangement with all the seats available. After seats are booked, you have to display the booked seats with "**") Validate the availability of the chosen seat (to check if the seat has been already booked or not). o You DO NOT have to do validation for an invalid entry like 23. We assume that the user enters a valid seat number that is displayed on the screen. You only need to check if it has been already booked or not. Calculate the ticket price.(You are allowed to use a global named constant for the price of economy class, however, wherever you have to display the cost of ticket, you need to use this function to determine the price of the ticket. • For instance, when you show the amount in the ticket that is displayed as output for each booking made. Display the ticket, as shown in the sample output, for each booking. The function used to calculate ticket price can be called from this function. DO NOT use global variables. Except that you are only allowed to use global named constants for the following: o Cost of economy class ticket. o An array for storing departure times and arrival times. o For the size of any other arrays you might use. DO NOT use classes to write this program (you should be able to write this program with the help of other data structures that you have learnt). Additional information/ Hints: o You need to store the details of a particular booking, because you have to display the booked seats in the seating arrangement with "**", when the program repeats. O Therefore, you need to think in the direction of storing the details of one booking which are of different data types, in one place. • Again, if you are making more than one booking, then you have to store the details of various bookings in an array. Apply what you have learnt and use appropriate data types and data structures. coS1511/103/1/2020 If you want to display the seat number as a combination of letter and number as in A1, A2 etc, then you can use the to_string () function to convert the integer to string and concatenate. For example: char row = 'A'; int col = 1l; string sNo - "; sNo += roW; sNo += to_string (col); Sample Program output (from one execution of the program without exiting): Nelcome to Cos1511 Flight Booking system Enter full name Hannah George The available travel times for flights are: Depart 1. 7.00 2. 9.00 3. 4. 5. 15.00 Choose the time by antering the option number from the displayed list: Arrive 9.30 11.30 11.00 13.30 13.00 15.30 17.30 Incorrect option! Please choose from 1-5. Validation for time option chosen The available seats for 7.00 are as follows: First Class(1920.00) |A1|A2|A3|---- |A4|A5|A6| 81|82|B3| Ic1|c2|C3| D1|02|D3|---- D4 D5 D6| Economy class(1600.00) E1|E2|E3|---- |E4|E5|E6| IF1|F2|F3| |G1|G2|G3| H1|H2|H3|---- |H4|H5 H6| 1|12| Please key in a seat number to choose a seat(eg:A2) A1 İB84|B5|B6| |C4|cs|C6| |F4|F5|F6| İG4|G5|66| CS1511/103/1/2020 Travel ticket for FLIGHT ******* : Hannah George Travel Ticket class : First class Seat No Departure Time Name : A1 7.00 : 9.30 Departure Destination ****** : Johannesburg : Cape Town Arrival Time ******* Amount:R1928.00 Thank you for booking with COs1511. Your travel agent for queries is Annie Mathew Do you want to make another booking(Y/N)? welcome to Cos1511 Flight Booking system Enter full name Deon Pieters Ticket display for a booking The available travel times for flights are: Depart 1. 7.00 2. 9.00 3. 11.00 13.00 Arrive 9.30 11.30 13.30 15.30 4. 5. 15.00 17.30 Choose the time by entering the option number from the displayed list: The availeble seats for 7.00 are as follows: t Class(1920.00) A2 A3] B1 82 B3| |c1|c2|c3|- |D1|02|03| Econony class(1600.00) |E1 E2|E3|- |E4|ES|E6| F1|F2|F3|- IG1|G2|G3| H1 |H2|H3| 11|12| A4|A5 A6 84 B5 86| |C4|c5|C6| |D4 D5|06| Seats booked should be indicated with |F4|F5|F6| (4|G5|66| Seats that are already taken are indicated with an asterisk Please key in a seat number to choose a seat(eg:A2) G3 Travel ticket for FLIGHT Travel Ticket class : Economy class : G3 : 7.00 : 9.30 Name : Deon Pieters Seat No Departure Destination : Johannesburg : Cape Town Departure Time Arrival Time Amount:R1600.00 Thank you for booking with cos1511. Your travel agent for queries is Annie Mathew ...*** Do you want to make another booking(Y/N)? coS1511/103/1/2020 Welcome to cos1511 Flight Booking system Enter full name bim Baker The available travel times for flights are: Depart 1. 7.00 9.00 Arrive 9.30 2. 3. 4. 5. 15.00 Choose the time by entering the option number from the displayed list: 1 11.30 11.00 13.30 13.00 15.30 17.30 The available seats for 7.00 are as follous: Eirst Class(1920.00) ** A2|A3|---- |A4|A5|A6| |B4|B5|B6| |C4|c5|C6| D1 D2|D3|---- |D4|D5|D6| Economy class(1600.00) E1|E2|E3|---- |E4|E5|E6| |F4|F5|F6| |G4|65|G6| |H4|H5 H6| ter 82 B3|- |c1|c2|c3|- Two seats booked for 7:00 am flight iF1|F2i- H1|H2TH3- Seats that are already taken are indicated with an asterisk Please key in a seat number to choose a seat(eg:A2) A1 was already booked for 7:00 am flight. So display an appropriate message that the seat has already been taken. Sorry, the seat is taken. Please choose a seat that is available D6 * *** ...... Travel ticket for FLIGHT *.... Travel Ticket class : First class Seat No Departure Time Arrival Time Name : Jim Baker Departure Destination Johannesburg : Cape Town : D6 : 7.00 : 9.30 .*.... Amount:R1920.00 Thank you for booking with Cos1511. Your travel agent for queries is Annie Mathew ********* Do you want to make another booking(Y/N)? Welcome to Cos1511 Flight Booking system Enter full name Fiona Bruce The available travel times for flights are: Depart 1. 7.00 2. 9.00 3. 11.00 4. 13.00 5. 15.00 Choose the time by entering the option nueber from the displayed list: Arrive 9.30 11.30 13.30 15.30 17,30 10 coS1511/103/1/2020 The available seats for 15.00 re as follows: First Class(1920.00) IA1|A2|A3|- JA4|AS|A6| i81|82|B3|---- |84|85|86| icijc2|c3|---- (c4lcsic6| [01 02|03|---- 04 05 D6| |Economy class(1600,00) ie1|E2|E3|---- JE4|ES|E6| F1|F2|F3| I61|62|63|---- 64|65|66| H1|H2|H3|--- |11|12| Please key in a seat number 12 A different flight time chosen, and a corresponding display. No bookings were made for this time, so all seats |F4|FS|F6| available. |H4|HS|H6| choose a seat(eg:A2) Travel ticketfor FLIGHT Nane : Fiona Bruce Travel Ticket class : Economy class : 12 : 15.00 : 17.30 Seat No Departure Destination : Johannesburg : Cape Town Departure Timne Arrival Time Amount: R1600.00 Thank you for booking with COs1511. Your travel agent for queries is Annie Mathew ...... Do you want to make another booking(Y/N)? Mimber of bookings made for 7.00 a.m:3 Number of bookings made for 9.00 a.m:0 Number of bookings made for 11.00 a.m:0 Number of bookings made for 13.00 p.m:0 er of bookings made for 15.00 p.m:1 The program should display the total bookings for each time, before exiting. execution time : 125.236 s Process returned e (exe) Press any key to continue. (TOTAL: 100 Marks) A sample program execution is provided at the end of the document, to help you visualize and understand what the program should do. You should use the same input as the sample program, for the screenshots that you submit with your assignment. The flight route is from Johannesburg to Cape Town with the travel duration fixed at 2 % hours. Departure and arrival locations remain the same. o Departure is always from Johannesburg and destination is aiways Cape Town. The departure and arrival times are: Option Departure Time Arrival Time 7:00 9:30 2 9:00 11:30 3 11:00 13:30 4 13:00 15:30 5 15:00 17:30 The seating arrangement is six seats in a row, three on the left side and three on the right side of the plane with a walkway (passage) in between. See the image of the setup below. (image source: http://travelgurureviews.com/kulula-com-reviews/airline-reviews/) o The total number of seats in the flight is 50. You are required to write a program that simulates a flight booking system. COS1511/103/1/2020 There are two classes of travel: First Class and Economy class. • The front four rows are considered as 'First Class' and all other rows to the back are 'Economy Class'. o The cost for economy class is fixed at R1 600.00. • The first class travel ticket is 20% more costly than the economy class. Questions You are required to do the following. (See the sample output screenshots for clarification). Write a program that will do the following: 1. Prompt (ask) the user to enter his/her full name. Welcome to Cos1511 Flight Booking system Enter full name Hannah George 2. Then display a menu showing the available times for the flight. The user can choose a preferred departure time (option 1 -5). The option selected should be validated for 1-5. Welcome to COs1511 Flight Booking system Enter full name Hannah George The available travel times for flights are: Depart 1. 2. 3. 11.00 Arrive 7.00 9.30 9.00 11.30 Validation for time option 13.30 15.30 17.30 chosen 4. 13.00 5. 15.00 Choose the time by entering the option numbe from the displayed list: Incorrect option! Please choose from 1-5. 3. If the user has entered a valid option, the seating arrangement for that particular flight time should be displayed to the user for the user to choose a seat. The available seats for 7.00 are as follows: First Class(1920.00) |A1|A2|A3|---- |A4|AS| A6| I81|B2|83|--- B4|B5| B6| |ci|c2|c3|- D1 D2 D3|---- D4|D5|D6İ Economy class(1600.00) |E1|E2|E3| -- IF1|F2İF3|- |G1|G2|G3|- H1|H2|H3|- i11|12| Please key in a seat number to choose a seat(eg:A2) A1 icajcsic6i TE4|ES|E6| İF4|FSİF6| |G4|G5|G6| If any seats have already been booked for that time, the booked seats should be indicated and displayed using "**". cOS 1511/103/1/2020 The user can then choose a suitable seat number that is available. The seat number should be validated to see if it has already been booked. In other words, if the user enters a seat number that is aiready booked, display a user-friendly message and give the option to enter the seat number again. The available seats for 7.00 are as follows: Flest Class(1920.00) Booked seats indicated with "*** BI[82|83| |c1]c2|c3] |D1|02|03| |Economy class(1600.00) |E1|E2|E3| |F1|F2|F3| IG1|G2|G3| H1|H2|H3| |84|B5|B6| (c4|c5|C6| |04 |D5|D6| |E4|ES|E6| ĮF4|FS|F6| ĮG4|GS|G6| |H4|H5 H6| Seats that are already taken are indicated with an asterisk Please key in a seat number to choose a seat(eg:A2) G3 4. Once the user has successfully chosen an available seat, a Flight booking ticket should be displayed on the screen. Check the sample screenshot for the details that need to be displayed on the ticket. Travel ticket for FLIGHT Name : Hannah George Travel Ticket class : First class : Al : 7,00 : 9.30 Seat No Departure Destination : Johannesburg Cape Town Departure Time Arrival Time ******* . Amount:R1920.00 Thank you for booking with cos1511. Your travel agent for queries is Annie Mathew ******* 5. The program should prompt (ask) the user if they would like to make additional bookings? Then the program should be able to repeat for more than one booking with various flight times. The check for 'y' or 'n' at the "Do you want to continue(Y/N)?" prompt should be case-insensitive. In other words, both Y' and 'y' should be accepted or both 'N' and 'n' should be accepted. Travel ticket for FLIGHT Name Hannah George Departure Destination 1 Johannesburg I Cape Town Travel Tieket class i First class Seat No Departure Time Arrival Time : Al : 7.00 I 0.30 Amount: R1920.00 Thank you for booking with cos1511. Your travel agent for queries is Annie Mathe Do you want to make another book Ing (Y/N)? Melcome to COSTSTI FaE Booking system Enter full name Deon Pieters The available travel tiimes for f1ights are: Depart 1. 7.00 2. 9.00 a. 11.00 4. 13.00 5. 15.00 Choose the time by entering the option number from the displayed list: Arrive 9.30 11. 30 13. 30 15. 30 17. 30 6. When the user has finished all the booking and chosen 'N' or 'n' at the "Do you want to continue(Y/N)?" prompt, the program should display the total number of bookings made for each flight time, just before exiting. mber of bookings made for 7.00 a.m:3 Number of bookings made for 9.00 a.m:0 Number of bookings made for 11.00 a.m:0 Number of bookings made for 13.00 p.m:0 Number of bookings made for 15.00 p.m:1 The program should display the total bookings for each time, before exiting. Process returned e (exe) Press any key to continue. execution time 125.236 s Submit the full program code and output screenshots. Include screenshots in your submission showing: the program repeating; input validations; booking for different flight times. You are required to define and use functions to do the following: Display the menu for flight times, accept the user option and validate the user option. • Call the function to validate the menu option from here. Validate the menu option for flight times. Display the seating arrangement (You might have to use two different functions for seat display). o ie. before any booking has been made, you have one seating arrangement with all the seats available. After seats are booked, you have to display the booked seats with "**") Validate the availability of the chosen seat (to check if the seat has been already booked or not). o You DO NOT have to do validation for an invalid entry like 23. We assume that the user enters a valid seat number that is displayed on the screen. You only need to check if it has been already booked or not. Calculate the ticket price.(You are allowed to use a global named constant for the price of economy class, however, wherever you have to display the cost of ticket, you need to use this function to determine the price of the ticket. • For instance, when you show the amount in the ticket that is displayed as output for each booking made. Display the ticket, as shown in the sample output, for each booking. The function used to calculate ticket price can be called from this function. DO NOT use global variables. Except that you are only allowed to use global named constants for the following: o Cost of economy class ticket. o An array for storing departure times and arrival times. o For the size of any other arrays you might use. DO NOT use classes to write this program (you should be able to write this program with the help of other data structures that you have learnt). Additional information/ Hints: o You need to store the details of a particular booking, because you have to display the booked seats in the seating arrangement with "**", when the program repeats. O Therefore, you need to think in the direction of storing the details of one booking which are of different data types, in one place. • Again, if you are making more than one booking, then you have to store the details of various bookings in an array. Apply what you have learnt and use appropriate data types and data structures. coS1511/103/1/2020 If you want to display the seat number as a combination of letter and number as in A1, A2 etc, then you can use the to_string () function to convert the integer to string and concatenate. For example: char row = 'A'; int col = 1l; string sNo - "; sNo += roW; sNo += to_string (col); Sample Program output (from one execution of the program without exiting): Nelcome to Cos1511 Flight Booking system Enter full name Hannah George The available travel times for flights are: Depart 1. 7.00 2. 9.00 3. 4. 5. 15.00 Choose the time by antering the option number from the displayed list: Arrive 9.30 11.30 11.00 13.30 13.00 15.30 17.30 Incorrect option! Please choose from 1-5. Validation for time option chosen The available seats for 7.00 are as follows: First Class(1920.00) |A1|A2|A3|---- |A4|A5|A6| 81|82|B3| Ic1|c2|C3| D1|02|D3|---- D4 D5 D6| Economy class(1600.00) E1|E2|E3|---- |E4|E5|E6| IF1|F2|F3| |G1|G2|G3| H1|H2|H3|---- |H4|H5 H6| 1|12| Please key in a seat number to choose a seat(eg:A2) A1 İB84|B5|B6| |C4|cs|C6| |F4|F5|F6| İG4|G5|66| CS1511/103/1/2020 Travel ticket for FLIGHT ******* : Hannah George Travel Ticket class : First class Seat No Departure Time Name : A1 7.00 : 9.30 Departure Destination ****** : Johannesburg : Cape Town Arrival Time ******* Amount:R1928.00 Thank you for booking with COs1511. Your travel agent for queries is Annie Mathew Do you want to make another booking(Y/N)? welcome to Cos1511 Flight Booking system Enter full name Deon Pieters Ticket display for a booking The available travel times for flights are: Depart 1. 7.00 2. 9.00 3. 11.00 13.00 Arrive 9.30 11.30 13.30 15.30 4. 5. 15.00 17.30 Choose the time by entering the option number from the displayed list: The availeble seats for 7.00 are as follows: t Class(1920.00) A2 A3] B1 82 B3| |c1|c2|c3|- |D1|02|03| Econony class(1600.00) |E1 E2|E3|- |E4|ES|E6| F1|F2|F3|- IG1|G2|G3| H1 |H2|H3| 11|12| A4|A5 A6 84 B5 86| |C4|c5|C6| |D4 D5|06| Seats booked should be indicated with |F4|F5|F6| (4|G5|66| Seats that are already taken are indicated with an asterisk Please key in a seat number to choose a seat(eg:A2) G3 Travel ticket for FLIGHT Travel Ticket class : Economy class : G3 : 7.00 : 9.30 Name : Deon Pieters Seat No Departure Destination : Johannesburg : Cape Town Departure Time Arrival Time Amount:R1600.00 Thank you for booking with cos1511. Your travel agent for queries is Annie Mathew ...*** Do you want to make another booking(Y/N)? coS1511/103/1/2020 Welcome to cos1511 Flight Booking system Enter full name bim Baker The available travel times for flights are: Depart 1. 7.00 9.00 Arrive 9.30 2. 3. 4. 5. 15.00 Choose the time by entering the option number from the displayed list: 1 11.30 11.00 13.30 13.00 15.30 17.30 The available seats for 7.00 are as follous: Eirst Class(1920.00) ** A2|A3|---- |A4|A5|A6| |B4|B5|B6| |C4|c5|C6| D1 D2|D3|---- |D4|D5|D6| Economy class(1600.00) E1|E2|E3|---- |E4|E5|E6| |F4|F5|F6| |G4|65|G6| |H4|H5 H6| ter 82 B3|- |c1|c2|c3|- Two seats booked for 7:00 am flight iF1|F2i- H1|H2TH3- Seats that are already taken are indicated with an asterisk Please key in a seat number to choose a seat(eg:A2) A1 was already booked for 7:00 am flight. So display an appropriate message that the seat has already been taken. Sorry, the seat is taken. Please choose a seat that is available D6 * *** ...... Travel ticket for FLIGHT *.... Travel Ticket class : First class Seat No Departure Time Arrival Time Name : Jim Baker Departure Destination Johannesburg : Cape Town : D6 : 7.00 : 9.30 .*.... Amount:R1920.00 Thank you for booking with Cos1511. Your travel agent for queries is Annie Mathew ********* Do you want to make another booking(Y/N)? Welcome to Cos1511 Flight Booking system Enter full name Fiona Bruce The available travel times for flights are: Depart 1. 7.00 2. 9.00 3. 11.00 4. 13.00 5. 15.00 Choose the time by entering the option nueber from the displayed list: Arrive 9.30 11.30 13.30 15.30 17,30 10 coS1511/103/1/2020 The available seats for 15.00 re as follows: First Class(1920.00) IA1|A2|A3|- JA4|AS|A6| i81|82|B3|---- |84|85|86| icijc2|c3|---- (c4lcsic6| [01 02|03|---- 04 05 D6| |Economy class(1600,00) ie1|E2|E3|---- JE4|ES|E6| F1|F2|F3| I61|62|63|---- 64|65|66| H1|H2|H3|--- |11|12| Please key in a seat number 12 A different flight time chosen, and a corresponding display. No bookings were made for this time, so all seats |F4|FS|F6| available. |H4|HS|H6| choose a seat(eg:A2) Travel ticketfor FLIGHT Nane : Fiona Bruce Travel Ticket class : Economy class : 12 : 15.00 : 17.30 Seat No Departure Destination : Johannesburg : Cape Town Departure Timne Arrival Time Amount: R1600.00 Thank you for booking with COs1511. Your travel agent for queries is Annie Mathew ...... Do you want to make another booking(Y/N)? Mimber of bookings made for 7.00 a.m:3 Number of bookings made for 9.00 a.m:0 Number of bookings made for 11.00 a.m:0 Number of bookings made for 13.00 p.m:0 er of bookings made for 15.00 p.m:1 The program should display the total bookings for each time, before exiting. execution time : 125.236 s Process returned e (exe) Press any key to continue. (TOTAL: 100 Marks)
Expert Answer:
Answer rating: 100% (QA)
include include include using namespace std string welcome void printseatsstring flight void populateseats bool validateflightstring a bool validateseatstring a int b bool validatebookstring a void pr... View the full answer
Related Book For
Posted Date:
Students also viewed these accounting questions
-
You are required to write a Project Demonstrating Excellence (PDE) Final Project paper. You will be expected to take a concept, theory or topic discussed/explained in the text (i.e. inventory...
-
Write a program that simulates stable storage. Use two large fixed-length files on your disk to simulate the two disks.
-
You are required to write a comprehensive social media marketing plan for a chosen company. You will prepare a social media marketing plan for the ABC Company (not real) that is working on...
-
The crate has a mass of 80 kg and is being towed by a chain which is always directed at 20 degrees from the horizontal. If the magnitude of P is increased until the crate begins to slide, determine...
-
Wesley and Myrtle (ages 90 and 88, respectively) live in an assisted care facility and for 2013 and 2014 received their support from the following sources: Percentage of Support Social Security...
-
An electric motor, having an unbalance of \(2 \mathrm{~kg}-\mathrm{cm}\), is mounted at the end of a steel cantilever beam, as shown in Fig. 9.51. The beam is observed to vibrate with large...
-
For Advent Company, the budgeted cost for one unit of product is direct materials \($10\), direct labor \($20\), and manufacturing overhead 80% of direct labor cost. If 25,000 units are expected to...
-
Wyrick Inc. had the following transactions pertaining to investments in common stock . Jan. 1 Purchased 2,500 shares of Murphy Corporation common stock (5%) for $140,000 cash plus $2,100 brokers...
-
Evaluate Sc (xy+x+2) ds along the curve r(t) = 2ti + tj + (9 2t)k, 0 t 1. Sc (xy+x+2) ds = (Simplify your answer.)
-
Consider the following Mini-Triangle program let in yarn: Integer; proc p () - nn 2 begin n = 9; p() end (a) Draw the decorated AST for this program (b) Produce the identification table for this...
-
Research the Delphi technique online and cite your source. Describe the Delphi technique and write about what you learned on the Web site you visited. Include a graphic chart, logo, or whatever you...
-
A pizza place advertises that they have 2 types of crust (round, square) and 5 toppings (pepperoni, sausage, bacon, green peppers, mushrooms). You call and order a pizza with 1 topping and tell the...
-
An entity reported an impairment loss of P2,200,000 in 2019. The impairment loss was related to an equipment acquired on January 1, 2011 for P16,000,000 with no residual value. Straight line annual...
-
Blue Ltd. has the following account balances: Sales $117000, Cost of Goods Sold $67200, Interest Revenue $460, Depreciation Expense $22340, Sales Discounts $4240, Interest Expense $1580, Utilities...
-
Let f(x) = 2x-4 and let g(x) = 4x+ 1. Find (f + g)(2).
-
What are the challenges and opportunities in deciphering the "dark matter" of the genome, including non-coding regions, repetitive elements, and structural variants, and how do these genomic features...
-
Camille, Inc., sold $155,000 in inventory to Eckerle Company during 2020 for $250,000. Eckerle resold $119,000 of this merchandise in 2020 with the remainder to be disposed of during 2021. Assuming...
-
How does health insurance risk differ from other types of insurance risk (e.g., automobile or homeowners insurance)? What is the difference between cost sharing and cost shifting? Is retiree health...
-
A computer with an 8-KB page, a 256-KB main memory, and a 64-GB virtual address space uses an inverted page table to implement its virtual memory. How big should the hash table be to ensure a mean...
-
Consider a system that hoards references to remote files as hints, for example as (name, remote-host, remote-name). It is possible that a remote file will quietly be removed and then replaced. The...
-
Windows uses a facility called Autoboost to temporarily raise the priority of a thread that holds the resource that is required by a higher-priority thread. How do you think this works?
-
Feng Company installs a computerized manufacturing machine in its factory at the beginning of the year at a cost of $42,300. The machines useful life is estimated at 10 years, or 363,000 units of...
-
In early January 2004, LabTech purchases computer equipment for $147,000 to use in operating ac tivities for the next four years. It estimates the equipments salvage value at $30,000. Prepare tables...
-
Cemer Manufacturing purchases a large lot on which an old building is located as part of its plans to build a new plant. The negotiated purchase price is $225,000 for the lot plus $120,000 for the...
Study smarter with the SolutionInn App