You are on page 1of 3

[ASSIGNMENT#2]

[OPERATING SYSTEM THEORY]

SYED HAMZA IBRAR GILLANI


ROLL NO: FA-2019-BSSE-060
SECTION: B

Submitted to: Sir Hassaan Rafique

Dated: 16-April-2021
Problem:
Consider the 5 processes:

Process Id Arrival Time Burst Time


P1 0 8

P2 2 5

P3 4 2

P4 6 1

P5 7 4

Solution:

Process Id Arrival Time Burst Time Remaining Time


P1 0 8 6
P2 2 5 3

P3 4 2 2
P4 6 1 0

P5 7 4 4
Gantt chart:

P1 P2 P3 P4 P2 P5 P1

0 2 4 6 7 10 14 20

Average Weight:
Average Time = (12+3+0+0+3)
5
= 18/5 = 3.6

You might also like