Programming Question

Question: Explain why it might be considered bad practice to lock on a string as per the following C# code: lock ("my lock") { this.Name = "foo"; this.Update(); }

From: Ace the Programming Interview [Guiness]

Subject: Concurrency

Load Another Question


Select a Subject