ITPEC FE Subject A October 2024 Question 15
ITPEC FE Subject A October 2024 — Question 15 of 60
FCFS Scheduling — Waiting Time — calculate waiting time for each process under First-Come-First-Serve.
Given processes with arrival and burst times, FCFS executes in arrival order without preemption.
Timeline:
- P1: arrives 0, starts 0, ends 0+6=6 → wait = 6-0-6 = 0
- P2: arrives 2, starts 6, ends 6+4=10 → wait = 6-2 = 4
- P3: arrives 4, starts 10, ends 10+9=19 → wait = 10-4 = 6
- P4: arrives 5, starts 19, ends 19+7=26 → wait = 19-5 = 14
Result: P1=0, P2=4, P3=6, P4=14 → (b)
Formula: waiting_time = start_time - arrival_time
- start_time of process = end_time of previous process (or arrival_time if CPU is idle)
Why not others:
- (a) 0,2,4,5 — these are the arrival times, not waiting times
- (c) 6,4,9,7 — these are burst times for P1,P2,P3,P4
- (d) 6,6,13,12 — incorrect calculation of start times
Key rule: FCFS = no preemption, strict arrival order. Waiting = time spent in ready queue before execution begins.
AI-generated — may contain errors
The original exam layout is preserved in the image so diagrams, formulas, tables, and code remain accurate.
This question comes from an official ITPEC past paper. ITPEC Practice is an independent study tool and is not affiliated with ITPEC. See the official FE past-paper collection or Report an issue.