Multiple Choice
Assume three threads share a BankAccount object with a balance initially zero (0) , a ReentrantLock named myLock, and a condition object on myLock named insufficientFunds, as shown below.Thread one calls withdraw(30) , then thread two calls withdraw(20) and thread three calls deposit(45) .What is the balance after the three calls and after the waiting threads have had a chance to run?
A) 0
B) 15 or 25
C) 45
D) -5
Correct Answer:

Verified
Correct Answer:
Verified
Q1: Consider the following change to the deposit
Q3: The _ method is useful only if
Q4: Which phrase best describes the purpose of
Q5: Why does the textbook recommend signallAll over
Q6: Which exception must be caught or declared
Q7: Suppose run1 and run2 are objects of
Q8: For threads of equal priority, which is
Q9: Which method do you call to make
Q10: Which are ways that a thread can
Q11: Examine the SharedData class shown below.Suppose two