Is it not entirely possible that the ReceivingThread never gets a chance to execute and the SendingThread KEEEEEEPPPSSS....... on executing without leaving the lock on the Semaphore object at all?
I got this example from Jakob Jenkov - Concurrency tutorial.
Can some one please elaborate and explain the example below about how the Semaphore is actually behaving like a Semaphore?
You don't know me, but I've been looking all over the world for. Thanks to the help from this tiny ad: