Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C++ Code The answer on another post doesn't work. Please only post working code in visual studio 2015. A supermarket must have enough cashiers to

C++ Code

The answer on another post doesn't work. Please only post working code in visual studio 2015.

A supermarket must have enough cashiers to work during certain hours to ensure that the customers move quickly to cash out. When dealing with this type of problem we must consider both the customer and the cashier as objects. We need to know how long a customer is in the queue. The queue time can be randomly generated in a reasonable range of times. One possibility is a time range from 30 seconds to 10 minutes. You will need to consider the probability of being in the queue for each customer. You do not need to have a probability for each customer, just for one or two times of day. For example, a customer who comes in off peak may have a .75 probability of being in line for 2 minutes, one who comes in during peak hours may have a .95 probability of being in line 10 minutes. Consider the following: You will have to also consider the probability of the cashier being busy or free to serve another customer. If more than 6 customers are in a line, then another cashier must open a line and customers must be redistributed. Your program will need to loop to simulate the passing of a certain amount of time. The store has a total of 9 cash registers and an appropriate number shall be open based criteria of no more than 6 customers in line at a time. If all registers are open then the lines may be longer than 6 customers.

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

Learning PostgreSQL

Authors: Salahaldin Juba, Achim Vannahme, Andrey Volkov

1st Edition

178398919X, 9781783989195

More Books

Students also viewed these Databases questions