Problems with FCFS
• Average waiting time can
be large if small jobs wait
behind long ones (high
turnaround time)
– Non‐preemptive
– You have a basket, but
you’re stuck behind
someone with a cart
• Solution?
– Express lane (12 items or
less)
Shortest Job First (SJF)
• Shortest Job First (SJF)
– Choose the job with the smallest expected duration first
• Person with smallest number of items to buy
– Requirement: the job duration needs to be known in
advance
– Used in Batch Systems
– Optimal for Average Waiting Time if all jobs are available
simultaneously (provable). Why?
– Real life analogy?
• Express lane in supermarket
• Shortest important task first
‐‐ The 7 Habits of Highly Effective People