See, as P and Q processes do not require any additional resource
This means, they will end and free all the resources that they are holding
Now Currently available resources in the sysem = 0 (given )
Now, when P and Q will finish executing, they will rekease Xp and Xq resources
New Available = Xp + Xq
Now this new available must be enough for the minimum need of the Processes.
This means that we have to find such a process, whose minimum need is less or equal to available
Isnt this the condition for banker’s Algorithm
So it is simple
Xp+Xq >= min(Yk)
where k not equal to p,q