Answer
See explanation
Work Step by Step
The conditions that can lead to a deadlock are given below :
1. Mutual exclusion : means there must exist at least one resource in the system which can be used by only one process at a time.
2. Hold and wait : There must exist a process which holds some resource and waits for another resource held by some other process.
3. No preemption : Once the resource has been allocated to the process, it can not be preempted.
4. Circular set : All the processes must wait for the resource in a cyclic manner where the last process waits for the resource held by the first process.