ALL > Computer and Education > courses > university courses > undergraduate courses > Operating System > ZSTU class(2019-2020-1) > student directories > 2017329621012-曹秋斌 >
homework 3 Version 0
👤 Author: by 283385508qqcom 2019-10-09 15:05:59
METHOD1: FCFS

process   burst time

p1             20

p2              5

p3               5

0 =>20=>25=>30

average time wait=(0+20+25)/3=15ms

if change the order to p3->p2->p1

5=>10=>30

average time wait=(0+5+10)/3=5ms

 

METHOD2:SJF

process   Burst time

p1            2

p2           10

p3         4

p4            7

p1=>p3=>p4=>p2

2=>6=>13=>23

avg=(0+2+6+13)/4=5.25 ms

 

METHOD3: shortest-remaining-time-first

process arrival time     burst time

p1    0     15

p2    1       3

p3     2      8

p4      3     1

p1=>p2=>p4=>p3=>p1

0=>1=>4=>5=>13=>27

avg=(14+3+2+11)/4=7.25ms

 

Please login to reply. Login

Reversion History

Loading...
No reversions found.