
Explanation:
Basically for producer and consumer problem solving for producer using wait () and notify All ()
is if synchronization is o then
{
  while (! IsitTrue()) {
    o.wait();
  }
if o.notify () call appear more than one waiting thread
then return from the o.wait () makes the condition in false state , than other will go back to waiting.