Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

the c + + code for the following system : Assume the Jerusalem Bank is start at 8 AM and end at 2 PM every

the c++ code for the following system : Assume the Jerusalem Bank is start at 8 AM and end at 2 PM every day.
The customers need to do tasks in the bank.
The customer-task is a class with the following attribute:
1. Task ID
2. Task name //credit, debit, query, open an account, close an account, etc...
3. Task arrival time// must between 8 AM and 2 PM
4. Task wait time// the waiting time before the task is starting (start time arrival time)
5. Task start time// when the task is being served. (arrival time + wait time)
6. Task period time//the number of minutes needed to finish the task.
7. Task Priority// there are 3 types of priorities
a. Normal task (has no priority)
b. Important // in this case we decrease 2 minutes from the arrival time
c. VIP // in this case we decrease 5 minutes from the arrival time
This simulation of the bank system should be implemented using queue fundamentals.
Create the following menu to simulate and implement the above system
1. Add a task //add a single task with necessary information
2. Add n number of tasks. // create n tasks with random information in an array, then sort the array according to the arrival time and insert it to the queue.
3. R-arrange the queue //check the wait time for each 5 minutes wait move the task one position toward the front of the queue.
4. Print task information
5. Total wait time for all tasks
6. Time needed to finish all tasks
7. How many task cant complete and done today
8. Print the information of a served task
9. Print the information of all tasks not yet served.
10. Exit

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Data And Information Quality Dimensions, Principles And Techniques

Authors: Carlo Batini, Monica Scannapieco

1st Edition

3319241060, 9783319241067

More Books

Students also viewed these Databases questions

Question

3. Experiment with cooperative learning activities.

Answered: 1 week ago

Question

=+which it operates?

Answered: 1 week ago

Question

=+How should we organize a book to maximize learning and interest

Answered: 1 week ago