Consider a system with four processes and four resources as follows:
P is a set of processes as P= {P1, P2, P3, P4}
R is a set of resources as R= {R1, R2, R3, R4}
R1, R2, R3 and R4 have two instances. The Snapshot at time T0 has the following situation:
 P1 allocates an instance of R1 and R3 while requesting an instance of R2.
 P2 allocates an instance of R2 and R4 while requesting an instance of R1.
 P3 allocates an instance of R1 and request R4.
 P4 allocates an instance of R2 and doesn’t need any other resource.
1. Draw the resource allocation graph.