A semaphore is a shared integer variable __________
2024
A semaphore is a shared integer variable __________
- A.
that can not drop below zero
- B.
that can not be more than zero
- C.
that can not drop below one
- D.
that can not be more than one
Attempted by 130 students.
Show answer & explanation
Correct answer: A
Answer: a
Explanation: A semaphore is a shared integer variable that can not drop below zero. In binary semaphore, if the value of the semaphore variable is zero that means there is a process that uses a critical resource and no other process can access the same critical resource until it is released. In Counting semaphore, if the value of the semaphore variable is zero that means there is no resource available.