Question: Using C or C++, and a linked list structure, please complete the following... Create a C or C++ program that reads a list of process

Using C or C++, and a linked list structure, please complete the following... Using C or C++, and a linked list structure, please complete the

Create a C or C++ program that reads a list of process names and integer times from stdin/cin and simulates round-robin CPU scheduling on the list. The input is a list of lines each consisting of a process name and an integer time, as shown below ProcesSA 4 ProcessB 10 Read the list and represent it in a linked list data structure and use the alarm system call to schedule a timer interrupt every 2 seconds. The interrupt handler should pick the next process from the process list and write out how much time the process has left to execute, as shown below ProcesSA 4 Update the time left to execute by subtracting 2 seconds and returning it to the end of the queue. If the process runs out of time, the write something like ProcessA Finished then delete the process from the linked list. If we have no more processes left, you write a message saying No processes left And exit the program

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!