In Question 10 from Chapter 9 of K&B's book, the answer is A. I would have answered A and B. Can you explain why B is not correct ?
Question 10 page 750:
Assume the following method is properly synchronized and called from a thread A on an object B:
After calling this method, when will the thread A become a candidate to get another turn at the CPU? A. After object B is notified, or after two seconds. B. After the lock on B is released, or after two seconds. C. Two seconds after object B is notified. D. Two seconds after lock B is released.
Also I think the is a mistake at page 731 where it's written:
The sentence should be: "it will NOT go"
Thanks in Advance for your help. [ March 17, 2008: Message edited by: Jean-Luc Thirion ]
maybe the answer B can be read like this: a lock is taken on B, we don't notify object B, we release the lock on B. Does this sequence make te thread A become a candidate to get another turn at the CPU.