184
Example of the banker’s algorithm
nHowever, if from the initial state, P1 request Q = (1,0,1). The resulting state would be:
            Claimed                Allocated               Available
3     2     2
6     1     3
3     1     4
4     2     2
2     0     1
5    1     1
2     1     1
0     0     2
0     1     1
P1
P2
P3
P4
nWhich is not a safe state since any process to finish would need an additional unit of R1. Request refused: P1 is blocked.
R1  R2  R3
R1  R2  R3
R1  R2  R3