| Problem | sync Tool Used |
Key Learning |
|---|---|---|
| Ping Pong | sync.Mutex |
Protect shared state |
| Producer–Consumer | sync.Mutex, sync.Cond |
Wait/notify on conditions |
| Sleeping Barber | sync.WaitGroup, Channels |
Use channels as queues |
| Dining Philosophers | sync.Mutex, sync.WaitGroup |
Prevent deadlocks |
| Worker Pool (Fan-in/out) | sync.WaitGroup |
Aggregate worker results |
| Heartbeat–Ward | Channels, Timers | Failure detection via signals |
Created
September 14, 2025 07:25
-
-
Save Anshuman-02905/22b6f43f893d7cdd8d5f51383aed3ffc to your computer and use it in GitHub Desktop.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment