Question: what is the difference between notify and notifyall in java?
Answer: Difference between notify vs notifyAll in Java First and main difference between notify() and notifyAll() method is that, if multiple threads is waiting on any lock in Java, notify method send notification to only one of waiting thread while notifyAll informs all threads waiting on that lock.