Final answer:
In computing, a binary semaphore can only have the integer values of 0 and 1, which signify the locked or unlocked state of a resource. The correct options for a binary semaphore's values are 0 and 1, not -1 or 0.5.
Step-by-step explanation:
A binary semaphore is used in computers and technology for process synchronization. It is a type of semaphore which can only take two values. By definition, a binary semaphore can only have the integer values 0 and 1. These two values are crucial because they represent the locked or unlocked state of a resource in multithreading environments. A value of 1 indicates that the semaphore is available for the process to take, effectively unlocking the resource. Conversely, a value of 0 means that the semaphore has been taken by some process, locking the resource until it is released.
It is important to note binary semaphores are utilized within operating systems and concurrent programming to ensure that only one thread or process can access the critical section at a time. When a process finishes using the resource, it signals (increments) the semaphore, which may wake up another waiting process. In the context of the choices provided, 0 (option c) and 1 (option a) are the correct ones. This is because binary semaphores do not take negative values like -1, nor do they deal with fractional numbers like 0.5.