UGC-NET | UGC-NET CS 2017 Nov – III | Question 49

Consider the following four processes with the arrival time and length of CPU burst given in milliseconds :
49
The average waiting time for preemptive SJF scheduling algorithm is __________.

(A) 6.5
(B) 7.5
(C) 6.75
(D) 7.75


Answer: (A)

Explanation: First we will make gantt chart of given process then we will calculate turn around time and waiting time of individual process.

Now we have to calculate average waiting time for schedule:

 avg waiting time = wt(P1 + P2 + P3 + P4 )/number of process.
   ie.             (9 + 0 + 15 + 2) / 4
                  = 26 / 4
                  = 6.5

So, option (A) is correct.

Quiz of this Question

My Personal Notes arrow_drop_up
Article Tags :

1


Please write to us at contribute@geeksforgeeks.org to report any issue with the above content.