### Implementation I-1 (Binary Semaphore initialized to 1):
A binary semaphore initialized to 1 provides strict mutual exclusion for the critical sections. At any point in time, at most one thread can execute inside its critical section.
Since each thread executes atomically with respect to the others:
5 increments add +5 to X.
3 decrements subtract −3 from X.
Final Value V1=10+5−3=12 Because mutual exclusion is guaranteed, no race condition can occur, so the minimum (and only) possible value of V1 is 12.
---
### Implementation I-2 (Counting Semaphore initialized to 2):
A counting semaphore initialized to 2 allows up to 2 threads to enter their critical sections concurrently. This enables race conditions where thread updates can be overwritten.
Each operation X=X±1 comprises three steps: Read(X), Modify, and Write(X).
To minimize the final value V2, we want all 5 increments to be overwritten while all 3 decrements take effect:
Thread D1 enters the critical section (s becomes 1), executes Read(X) and gets 10, computes 10−1=9, and is preempted before writing back.
Since s=1, all 5 incr threads (I1 to I5) execute one by one, updating X sequentially from 10 to 15.
Thread D1 resumes and writes its stored value 9 to X, completely overwriting all 5 increments.
Threads D2 and D3 execute normally one after another, decrementing X from 9→8→7.
Since X starts at 10 and there are at most 3 decrement operations, the value of X cannot decrease below 10−3=7.
Thus, the minimum possible value of V2 is 7.
Therefore, the minimum possible values of (V1,V2) are (12, 7), which corresponds to option (C).