Question: HI, this is DATA STRUCTURES AND ALGORTIHMS and my coding here using QUEUE STL. I want to modify the code for number 5 which is
HI, this is DATA STRUCTURES AND ALGORTIHMS and my coding here using QUEUE STL.
I want to modify the code for number 5 which is EXIT and the output will be like this diagram:

and here my coding, can you please modify for number 5 selection
#include
struct Patient { int q_no; string name; }; struct Patient p[100];
int menu() { int i; cout
cout>i; return i; }
void append(int n) { cout>p[n].name; cout>p[n].q_no; cout
void inQueue(int i) { int q; q=i; cout
void Display(int j) { int i; cout
void serve(int n) { string s; for(int i=1;i>s; if(s=="Y") { cout
int main() {
queue
cout Queue Number System 1) Generate queue 2) Get total waiting patients 3) Display all waiting patients 4) Serve patient 5) Exit Select Menu: 5 WARNING! Queue is not empty. Proceed? [Y/N]: Y Deleting data in queue... Thank you and goodbye
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
