Determine the average amount of time people spend waiting


The fancy new French restaurant La Food is very popular for its authentic cuisine and high prices. This restaurant does not take reservations. To help improve the efficiency of their operations, the Maitre De has hired you to write a program that simulates people waiting for tables. The goal is to determine the average amount of time people spend waiting for tables.

Your program will read in a list of event descriptions from a text file, one description per line.

- Arrival: A party has arrived to eat. Add them to the end of the list of waiting parties (a Queue) and tell them to wait at the bar (where strong drinks are served) until called. This event is described in the following format:

Here t is the time of arrival (in minutes past opening time), n is the number of people in the party, and name is the name to call when the table is ready.

- Table: A table has become available; remove the party that has been waiting the longest from your list, and seat them. This event is described in the following form:

Here t is the time the table became available (again, in minutes past opening time),

- Quit: This is a sentinel event indicating the end of the input file. It has the following form:

Q When the events in the file have been processed, compute and print the average waiting time per customer. If there are still people waiting for tables, print a summary of who is still waiting.

1. Listing (print-out) of your nicely formatted program source code (with comments and headers)

2. Print-out of the text file that contains your restaurant information

3. Screen captures of at least three sample runs/scenario output

4. High level design using UML notation (minimum of a use case diagram, a class diagram for Party class, & a sequence diagram)

5. Utilize the submission template provided in the course module.

Solution Preview :

Prepared by a verified Expert
JAVA Programming: Determine the average amount of time people spend waiting
Reference No:- TGS0913703

Now Priced at $50 (50% Discount)

Recommended (91%)

Rated (4.3/5)