I know the difference between those two was already discussed not once, but still don't really understand it in practice, for example here (K&B book, Chapter 9)
Regardless of whether I use notify() or notifyAll() in lines 26-27, all three Reader threads get notified and print their messages:
Thread[Thread-1,5,main]: Waiting for calculation...
Thread[Thread-3,5,main]: Waiting for calculation...
Thread[Thread-2,5,main]: Waiting for calculation...
Thread[Thread-2,5,main]: Total is: 4950
Thread[Thread-3,5,main]: Total is: 4950
Thread[Thread-1,5,main]: Total is: 4950
What is it that I am missing?