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...
-
According to Harpers Index, 50% of all federal inmates are serving time for drug dealing. A random sample of 16 federal inmates is selected. (a) What is the probability that 12 or more are serving...
-
Alternative adjustments-rent. Calco, Inc., rents its store location. Rent is $3,000 per month, payable quarterly in advance. On July 1, a check for $9,000 was issued to the landlord for the...
-
Copy your worksheet from Question 6 into another worksheet. Change the increase from 10% to 18%. Protect the worksheet, so that changes cannot be made. Question 6 Open a new spreadsheet. Type...
-
Burke Corporation was organized on January 1, 2014. It is authorized to issue 10,000 shares of 8%, $100 par value preferred stock, and 500,000 shares of no-par common stock with a stated value of $2...
-
Researchers were curious about the size of the bill at a restaurant based on whether a credit card was used to pay versus cash. The researchers took random samples of bills at restaurants across the...
-
Design the 4-to-1 MUX two ways Write a Verilog module called mux4to1 to implement 4-to-1 multiplexer using functional descriptions and if-else blocks. Write another Verilog module called...
-
The memo assignment describes the situation and requests a recommendation to the problem at hand through an assignment document. You need to individually identify the relevant analysis tool,...
-
Bowrah Brewery Ltd (Bowrah) is planning to launch a new product of fresh beer to the market. This project requires an initial investment in equipment and net working capital of $850,000. The finance...
-
Create a method that contains the source code below. Using java create a method using the string word "I LOVE JAVA PROGRAMMING" using instrcutions this is the source code: this is the source code^...
-
The surface area of a lake is estimated by measuring the width in meters of the lake at intervals of 100 m. The measurements are shown in the figure. Use numerical integration to estimate the area of...
-
You are considering opening a pizza restaurant in your town. Describe the production process that you envision taking place to deliver a fully cooked pizza to a customer. What components would be in...
-
Do you see any connection between your success or failures and how you study? Do you see any connections between your success or failures in your amount of media multitasking? Try out a technique...
-
FILING OF ANNUAL INCOME TAX RETURN FOR PURELY COMPENSATION INCOME EARNER Instructions: 1. Download BIR Forms 1700 AND 2316 Version 2018 at 2. Input ALL the necessary information in the returns (see...
-
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?
-
The required rate of return is 12%, and the expected rate of inflation over the life of the project is forecast to remain steady at 3%. Should you invest in this project?
-
For your answer to Problem 3.11, construct an argument as to why this selection process is useful for deciding which project is best. Now, construct a counterargument to criticize this choice. In...
-
Scoring Model. Suppose the information in Problem 3.13 was supplemented by importance weights for each of the four assessment criteria, where 1 = low importance and 4 = high importance: Assume, too,...
Study smarter with the SolutionInn App