i/o1 | i/o2 | i/o3 | i/o4 | i/o5 | i/o6 | i/o7 | i/o8 | i/o9 | i/o10 | cpu1 | ..... |
according to question given at every 1ms i/o operation done . and it will be completed in 10 ms . so 10 i/o operation have
time = 10*1+.1*10 = 11ms ...(here 0.1 switching overhead )
cpu task ,for which we can consider it runs for 10ms bcoz i/o operation will be completed in 10ms ... (given as all process are long running tasks)
so if case 1 ... time quantum is 1ms then cpu task takes = 10*1+10*0.1(switching after every 1ms quantum time)= 11ms
so cpu utilization = useful work/ total work
(10*1+10*1)/11+11= 20/22=90.90%
case 2 time quantum =10ms so cpu takes = 10*1+1*.1=10.1
cpu utilization = 20/ 11+10.1= 20/ 21.1 = 94.78%