ITPEC FE Morning October 2021 Question 17

Source exam: ITPEC FE Morning October 2021Topic: Computer Systems & Hardware

ITPEC FE Morning October 2021 — Question 17 of 80

Round Robin Scheduling — calculate average waiting time with a fixed time quantum.

Given processes P1=10, P2=23, P3=7, P4=3 with time quantum=10 ms, all arriving at time 0:

Simulation:
- 0–10: P1 runs 10 → done

- 10–20: P2 runs 10 → 13 left

- 20–27: P3 runs 7 → done

- 27–30: P4 runs 3 → done

- 30–40: P2 runs 10 → 3 left

- 40–43: P2 runs 3 → done

Waiting time = completion − arrival − CPU time:
- P1: 10 − 0 − 10 = 0

- P2: 43 − 0 − 23 = 20

- P3: 27 − 0 − 7 = 20

- P4: 30 − 0 − 3 = 27

Average = (0 + 20 + 20 + 27) / 4 = 67 / 4 = 16.75

Why not others:
- (a) 10.75 — underestimates waiting for later processes

- (b) 14.25 — likely a miscalculation of queue order

- (c) 15.00 — does not match the simulation

Key rule: Waiting time = completion_time − arrival_time − CPU_execution_time. Simulate each quantum step carefully; processes finishing early release CPU immediately.

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.