find average waiting time using Round Robin (time slice=4ms)? ProcessArrival TimeBurst TimeP108P214P329P435 Select one:a. 12.25b. 11.75c. 11d. 10
Question
find average waiting time using Round Robin (time slice=4ms)? ProcessArrival TimeBurst TimeP108P214P329P435 Select one:a. 12.25b. 11.75c. 11d. 10
Solution
To find the average waiting time using Round Robin scheduling, we need to calculate the waiting time for each process and then find the average. The time slice given is 4ms.
Here's how we can calculate it:
-
For process P1, it arrives at 0 and has a burst time of 8. Since the time slice is 4ms, it will run for 4ms, then it will wait for the remaining processes to complete their time slice. The remaining burst time for P1 is 4ms. The waiting time for P1 is the time it waits after the first time slice until it gets the CPU again, which is the sum of the time slices of P2, P3, and P4 (4ms each), so 12ms.
-
For process P2, it arrives at 1 and has a burst time of 4. It will run for 4ms after P1's first time slice. So, it waits for 4ms (P1's first time slice). The waiting time for P2 is 4ms.
-
For process P3, it arrives at 2 and has a burst time of 9. It will run for 4ms after P1 and P2 have had their time slices. So, it waits for 8ms (P1's first time slice + P2's time slice). After its first time slice, it will wait for P1's and P4's time slices (4ms each), so another 8ms. The total waiting time for P3 is 16ms.
-
For process P4, it arrives at 3 and has a burst time of 5. It will run for 4ms after P1, P2, and P3 have had their time slices. So, it waits for 12ms (P1's first time slice + P2's time slice + P3's first time slice). The waiting time for P4 is 12ms.
Now, we can calculate the average waiting time by adding up the waiting times and dividing by the number of processes:
(12ms for P1 + 4ms for P2 + 16ms for P3 + 12ms for P4) / 4 = 11ms
So, the average waiting time using Round Robin scheduling with a time slice of 4ms is 11ms. The correct answer is c. 11.
Similar Questions
Suppose you are running a system that accepts jobs in batches, and each batch consists of 100 jobs, each job takes 200ms to complete. Suppose the time slice is set to 10ms. What is the average response time in ms (rounded to the nearest integer) if the round robin scheduler is used? Assume that the system processes one batch at a time (so at any time there are at most 100 jobs running). Instructor notes: Provide your answer as a numerical value only
find average turnaround time using preemptive SJF ProcessArrival TimeBurst TimeP108P214P329P435 Select one:a. 13b. 20c. 10d. 14
Consider Five Processes P1 to P5 arrived at same time. They have stimated runningtime 10,2,6,8 and 4 seconds, respectively. Their Priorities are 3,2,5,4 and 1,respectively with 5 being highest Priority. Find the average turnaround time andaverage waiting time for Round- Robin(q=3) and Priority Schedulingalgorithm.
Consider the following three processes in the FCFS.Process ID. Brust-time. Arrival-timeP1 3 3P2 6 6P3 9 9What is the average waiting time?2345
Consider the given table below and find Completion time (CT), Turn-around time (TAT), Waiting time (WT), Response time (RT), Average Turn-around time and Average Waiting time in case of FCFS scheduling. Process ID Arrival time Burst time P1 2 2 P2 5 6 P3 0 4 P4 0 7 P5 7 4a.The waiting time for process P1 is 9msb.The waiting time for process P1 is 0msc.The waiting time for process P1 is 8msd.The waiting time for process P1 is 4ms
Upgrade your grade with Knowee
Get personalized homework help. Review tough concepts in more detail, or go deeper into your topic by exploring other relevant questions.