Which of the following process scheduling algorithm may lead to starvation (1)SJF
(2)SRTF
(3)Priority(without preemption)
(4)Priority(with preemption)
a)1,2,3 b)1,2,4
c)1,3,4 d)1,2,3,4
e)1,3 f)1,4
You should know about two things before solving this question Indefinite Blocking (Starvation) vs Definite Blocking .. Indefinite blocking means "we don't know how much time we should wait" Definite blocking means "we know how much time we should wait" So now think about the question In all the cases we don't know how much time we should wait. Point to recall : FCFS Scheduling is starvation free because we know how much time we should wait(sum of burst times of all the process which came earlier) Look at the Statement about FCFS :"Because there is no pre-emption, if a process executes for a long time, the processes in the back of the queue will have to wait for a long time before they get a chance to be executed." This is not starvation, we are just waiting ..... Hope this will make sense....Thank you
According to me the answer should be option 2 and 4 as they are premptive algorithms. There is difference between waiting and starvation. Hence option 1 and 3 lead to waits and option 2 and 4 leads to starvation.
64.3k questions
77.9k answers
244k comments
80.0k users