Bird
Raised Fist0

In a concurrent system, a deadlock occurs when:

medium📝 Analysis Q7 of Q15
LLD - Design — Parking Lot System
In a concurrent system, a deadlock occurs when:
AA thread finishes execution too quickly
BTwo or more threads wait forever for locks held by each other
CLocks are never acquired by any thread
DThreads run sequentially without waiting
Step-by-Step Solution
Solution:
  1. Step 1: Define deadlock

    Deadlock is a situation where threads wait indefinitely for resources locked by each other.
  2. Step 2: Match definition to options

    Two or more threads wait forever for locks held by each other correctly describes this circular waiting causing deadlock.
  3. Final Answer:

    Two or more threads wait forever for locks held by each other -> Option B
  4. Quick Check:

    Deadlock = circular wait for locks [OK]
Quick Trick: Deadlock means threads wait forever on each other [OK]
Common Mistakes:
MISTAKES
  • Confusing deadlock with fast thread completion
  • Thinking deadlock means no locks acquired
  • Assuming threads run without waiting

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More LLD Quizzes