Open In App

ISRO | ISRO CS 2020 | Question 45

Three CPU-bound tasks, with execution times of 15, 12 and 5 time units respectively arrive at times 0, t and 8, respectively. If the operating system implements a shortest remaining time first scheduling algorithm, what should be the value of t to have 4 context switches ? Ignore the context switches at time 0 and at the end.
(A) 0 (B) t = 0
(C) t (D) 3

Answer: (A)
Explanation: Using SRTF, if t = 2, gantt chart is

Hence, to have 4 context switches t should be between 0 Quiz of this Question

Article Tags :