Simulate the experience of a days business at a bank

Assignment Help Computer Engineering
Reference no: EM132109190

In the programming language of your choice, simulate the experience of a day's business at a bank.

Your implementation must make use of a min heap, and must fit the following criterion:

At program launch, it will query the user for the number of tellers working that day. There must be at least four tellers, and no more than ten tellers.

If a number is passed in outside of those bounds, have your program round up to four or down to ten as appropriate for the input.

Your tellers will be represented by the min-heap of a size equal to the number of tellers.

To start mo simulation generate 100-200 customers randomly, and place them in a queue.

Each customer will have a total service time that it will take to conclude their business.

Dequeue customers from the queue into your min-heap until it is full. The customer service time is the metric which will be used to balance the heap.

Pop the top customer off of your heap, and decrement the service time for all customers remaining in the heap.

If a customer which is still in the heap has their service time reach 0 in this process, remove that customer from the heap.

Populate the heap back to maximum capacity through dequeueing from your queue

Repeat steps 4 and 5 until both the heap and queue are empty Every 20 customers that pass out of the queue, print the current status of the queue (how many customers are left), and print the current composition of the heap.

Reference no: EM132109190

Questions Cloud

Design a program with loop that let the user enter a series : Design a program with loop that let the user enter a series of numbers. Compare each number to the current maximum and minimum.
Write a java program that will ask the user : Write a Java program that will ask the user to enter three integer numbers and find the greatest or the smallest of these numbers.
Create the logic for a program that performs functions : Create the logic for the methods sum() and difference(); they compute the sum of and difference between the values of two arguments, respectively.
Differences in the way the process is performed : ACC203 – Accounting Information Systems - What are the major differences in the way the process is performed - Explain how this case demonstrates
Simulate the experience of a days business at a bank : At program launch, it will query the user for the number of tellers working that day. There must be at least four tellers, and no more than ten tellers.
Write a program for converting us measurement values : Write a program for converting US measurement values to their corresponding metric measurement.
Design a payroll class with a string containing the employee : Write another program that demonstrates the class by creating a Payroll object , then asking the user to enter the data for an employee.
Write a void method named that accepts an integer array : Write a void method named clear that accepts an integer array , and the number of elements in the array and sets the elements of the array to 0.
Write a program to read in various types of test questions : Write a C++ program to read in various types of test questions (multiple choice and True/False) from a test bank (text file), and load the questions.

Reviews

Write a Review

Computer Engineering Questions & Answers

  Mathematics in computing

Binary search tree, and postorder and preorder traversal Determine the shortest path in Graph

  Ict governance

ICT is defined as the term of Information and communication technologies, it is diverse set of technical tools and resources used by the government agencies to communicate and produce, circulate, store, and manage all information.

  Implementation of memory management

Assignment covers the following eight topics and explore the implementation of memory management, processes and threads.

  Realize business and organizational data storage

Realize business and organizational data storage and fast access times are much more important than they have ever been. Compare and contrast magnetic tapes, magnetic disks, optical discs

  What is the protocol overhead

What are the advantages of using a compiled language over an interpreted one? Under what circumstances would you select to use an interpreted language?

  Implementation of memory management

Paper describes about memory management. How memory is used in executing programs and its critical support for applications.

  Define open and closed loop control systems

Define open and closed loop cotrol systems.Explain difference between time varying and time invariant control system wth suitable example.

  Prepare a proposal to deploy windows server

Prepare a proposal to deploy Windows Server onto an existing network based on the provided scenario.

  Security policy document project

Analyze security requirements and develop a security policy

  Write a procedure that produces independent stack objects

Write a procedure (make-stack) that produces independent stack objects, using a message-passing style, e.g.

  Define a suitable functional unit

Define a suitable functional unit for a comparative study between two different types of paint.

  Calculate yield to maturity and bond prices

Calculate yield to maturity (YTM) and bond prices

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd