Interview Questions

Suppose you have thread and it is in synchronized method and now can thread enter other synchronized method from that method?

Java Interview Questions and Answers (part 4)


(Continued from previous question...)

44. Suppose you have thread and it is in synchronized method and now can thread enter other synchronized method from that method?

Yes, here when thread is in synchronized method it must be holding lock on object’s monitor and using that lock thread can enter other synchronized method.

(Continued on next question...)

Other Interview Questions