Lab06 DSA
Lab06 DSA
CS‐F23
LAB‐08 Issue Date: March 24, 2025
Start Time: 11:45 AM
Total Marks: 25 Submission Time: 12:45 AM
The goal of this simulation is to model a bank queue system where different types of customers arrive at
regular intervals and are served based on First In, First Out (FIFO) order. There are multiple service
counters, each dedicated to specific customer types, and various rules govern how customers are assigned,
how long they wait, and when additional counters open.
struct Customer
{
int id;
int arrivalTime;
int serviceTime;
};
Example
Input:
Customers = [{1,0,3}, {2,2,15}, {3,4,4},{1,6,6}, {3,8,10}] , c = 4
Processing Customers
1. Time = 0
o Regular Queue → {1, 0, 3} starts at Counter 4 (finishes at T=3).
2. Time = 2
o Business Queue → {2, 2, 15} starts at Counter 3 (finishes at T=17).
3. Time = 3
o Regular Queue → {1, 6, 6} arrives but waits.
o Counter 4 is free.
4. Time = 4
o Senior Queue → {3, 4, 4} starts at Counter 1 (finishes at T=8).
5. Time = 6
o Regular Queue → {1, 6, 6} starts at Counter 4 (finishes at T=12).
6. Time = 8
o Senior Queue → {3, 8, 10} starts at Counter 1 (finishes at T=18).
Good Luck!
------------------------------------------------------
Note: You must complete all your tasks individually. Absolutely NO collaboration is allowed. Any case of
plagiarism/cheating would result in 0 marks in sessional activities.