Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Use your queue implementation to simulate a bank with 3 tellers and one line. The time between arrival of customers is a random integer between

Use your queue implementation to simulate a bank with 3 tellers and one line. The time between arrival of customers is a random integer between 1 and 5. When a customer arrives, the customer gets in line. When any of the three tellers is available, the first customer in line goes to that teller. The time to process that customer's transaction is another random integer between 1 and 5.

When the transaction is completed, the customer leaves. Run the simulation for 100 customers. Report the average time the customer waits in the queue. To do this, for each item enqueue, include its time. For each item dequeued, calculate the current time the time entering the queue.

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

Step: 3

blur-text-image

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

Mobile Usability

Authors: Jakob Nielsen, Raluca Budiu

1st Edition

0133122131, 9780133122138

More Books

Students also viewed these Programming questions

Question

Is there something else I need more?

Answered: 1 week ago