If there are 6 processes and each requires 2 resources.Then what are the minimum number of resources to prevent deadlock?

A) 6

B) 7

C)9

D)5

If there are 6 processes and each requires 2 resources.Then what are the minimum number of resources to prevent deadlock?

A) 6

B) 7

C)9

D)5

Use the deadlock free condition i.e. R>=P(N-1)+1.Here R=? , P=no. of processes =6 and N= request =2. which gives R>=6(2-1)+1 ie. R>=7. Hence **minimum number of resources to prevent deadlock is 7.**

suppose To occur deadlock all process acquires 1 resources (less than 1 it required) so 6 process acquires 6 requires. so to avoid deadlock we need at least one resource which will full fill the need of one process.later that process executes and releases resources which will be acquired by other process.