#include&lt;stdio.h&gt;   #include&lt;fcntl.h&gt;   #include&lt;sys/stat.h&gt;   #include&lt;semaphore.h&gt;&nbsp;   int main&#40;&#41;   &#123;       sem_t* sem_id;       int value;       sem_id = sem_open&#40;&quot;new_13&quot;,O_CREAT,0666,3&#41;;       if&#40;sem_id == SEM_FAILED&#41;           perror&#40;&quot;sem_open&quot;&#41;;       sem_wait&#40;sem_id&#41;;       sem_wait&#40;sem_id&#41;;       sem_wait&#40;sem_id&#41;;       sem_wait&#40;sem_id&#41;;       sem_post&#40;sem_id&#41;;       sem_post&#40;sem_id&#41;;       sem_getvalue&#40;sem_id,&amp;value&#41;;       printf&#40;&quot;%d\n&quot;,value&#41;;       if&#40;sem_close&#40;sem_id&#41; == -1&#41;           perror&#40;&quot;sem_close&quot;&#41;;       return 0;   &#125;
A. 2
B. 3
C. 0
D. none of the mentioned
Answer:A
#include&lt;stdio.h&gt;   #include&lt;fcntl.h&gt;   #include&lt;sys/stat.h&gt;   #include&lt;semaphore.h&gt;&nbsp;   int main&#40;&#41;   &#123;       sem_t* sem_id;       int value;       sem_id = sem_open&#40;&quot;new_13&quot;,O_CREAT,0666,3&#41;;       if&#40;sem_id == SEM_FAILED&#41;           perror&#40;&quot;sem_open&quot;&#41;;       sem_wait&#40;sem_id&#41;;       sem_wait&#40;sem_id&#41;;       sem_wait&#40;sem_id&#41;;       sem_wait&#40;sem_id&#41;;       sem_post&#40;sem_id&#41;;       sem_post&#40;sem_id&#41;;       sem_getvalue&#40;sem_id,&amp;value&#41;;       printf&#40;&quot;%d\n&quot;,value&#41;;       if&#40;sem_close&#40;sem_id&#41; == -1&#41;           perror&#40;&quot;sem_close&quot;&#41;;       return 0;   &#125;
A. 2 B. 3 C. 0 D. none of the mentioned
Explanation:This process will block when the sem_wait() has been called last time in this program.