This is a question from Dan C. Exam 20 Mock
Test.
Does the code mean there are 10 threads (0-9) synchronized with their own private Object and waiting. While the main
thread tries to synchronize on (this) which is itself (a bit confused which object this is holding on to)and then calls notifyAll.
Does it mean then that all 10 threads will be released and then print their name. Since they dont share a common private object all of them will then print their name.
Answer given was Nothing printed and Some or All of the threads will be printed.
My reasoning of nothing printed because main thread finishes and 10 threads are daemon threads. Right? But if they werent daemon all will be printed right? Also what if the private object they have is static. Does that mean only 1 thread will print their name?