Question
Which statement about Deadlocks and Race Conditions is the strongest interview answer?
- Deadlocks and Race Conditions is mostly a naming style choice and has little effect on runtime or design.
- A race condition depends on timing for correctness, while a deadlock stops progress because threads wait on each other indefinitely.
- Deadlocks and Race Conditions exists mainly to reduce the number of Java files in a project.
- Deadlocks and Race Conditions matters only for frontend frameworks, not for core Java applications.
Hint
Start with the core rule behind Deadlocks and Race Conditions.
Answer and rationale
Correct answer: B. A race condition depends on timing for correctness, while a deadlock stops progress because threads wait on each other indefinitely.
A race condition depends on timing for correctness, while a deadlock stops progress because threads wait on each other indefinitely. This is the base concept interviewers commonly test first.
Track: Java