What should not be done to avoid deadlock?
(a) Avoid using multiple threads
(b) Avoid hold several locks at once
(c) Execute foreign code while holding a lock
(d) Use interruptible locks
I have been asked this question in examination.
Question is from Multithreading topic in chapter Multithreading of Java