Pergunta de entrevista da empresa Publicis Sapient

which loop is preferred to use wait() and notify() in multithreading environment?