In reply to Shruti Kamble:
I assume you also changed sema.put(2) to (3).
If there are initially 4 keys, and each process needs 3 available keys, then only one process can run at a time.
In reply to Shruti Kamble:
I assume you also changed sema.put(2) to (3).
If there are initially 4 keys, and each process needs 3 available keys, then only one process can run at a time.