.NET & C# ยท C#
When should you use concurrency synchronization in C#?
Prefer immutability first. Use lock for short synchronous critical sections, SemaphoreSlim for async coordination, and concurrent primitives when they fit the access pattern.