The FIFO algorithm
2019
The FIFO algorithm
Answer: D. First executes the job that came in first in the queue. — ConceptA FIFO queue follows the first-in, first-out rule: an item is inserted at the rear and removed from the front. In process scheduling, this means jobs…
- A.
First executes the job that came in the last in the queue.
- B.
First executes the job that has maximum processor needs.
- C.
First executes the job that needs minimum processor.
- D.
First executes the job that came in first in the queue.
Attempted by 51 students.
Show answer & explanation
Correct answer: D
Concept
A FIFO queue follows the first-in, first-out rule: an item is inserted at the rear and removed from the front.
In process scheduling, this means jobs are selected by arrival order; processor demand is not used to reorder them.
Application
The job that entered the ready queue first is at the front of the queue.
FIFO therefore dispatches that earliest-arriving job before jobs that arrived later.
Contrast
The last-arrived-first rule corresponds to LIFO or stack-style selection, not FIFO queue removal.
Selecting maximum processor need uses a resource-demand criterion rather than arrival order.
Selecting minimum processor need uses a resource-demand criterion rather than arrival order.
Cross-check
For arrivals J1, J2, and J3, the queue front is J1, so the dispatch order begins J1, then J2, then J3.
Therefore, FIFO first executes the job that came first in the queue.