Object obj1 = new Object(); Object obj2 = new Object();
obj1 and obj2 are accessible to two different threads and the threads are about to call the getLocks() method. Assume the first thread calls the method getLocks(obj1, obj2). Which of the following is true? ________________________________________________________________ a The second thread should call getLocks(obj2, obj1) b The second thread should call getLocks(obj1, obj2) c The second thread should call getLocks() only after first thread exits out of it. d.The second thread may call getLocks() any time and passing parameters in any order.It should not call getLocks(obj2, obj1) because it may result in a deadlock. e None of the above
Option B is correct Is Anyone Having a explanation to this??
Thanks, With Regds, Anand
Thanks and Regards, Anand
SCJP 5.0 310-055 73%, SCWCD 1.4 310-081 78%, IBM DB2 9 Fundamentals 000-730 62%