Which CPU scheduling algorithm prefers the process with the shortest burst time?
Explanation
Right Answer:
Shortest Job First (SJF) Scheduling
Solution:
SJF algorithm us process ko sabse pehle select karta hai jiska CPU Burst Time sabse kam hota hai. Iska mathematical logic niche diya gaya hai:
Maan lijiye hamare paas n processes hain {P1,P2,…,Pn} aur unke burst times {B1,B2,…,Bn} hain. SJF us process Pi ko pick karega jiske liye:
Burst Time (Bi)=min{B1,B2,…,Bn}
Key Property:
SJF algorithm minimum average waiting time (Avg. Wt) dene ke liye optimal mana jata hai: