what is the advantage of using SEMAPHORES to ORDINARY
VARIABLES???
Answers were Sorted based on User's Feedback
Answer / sachin dohre
Working of Semaphore is Atomic i.e till semaphore released
no change in shared memory could occur,, while in case of
variables it could be changed while context switching
| Is This Answer Correct ? | 4 Yes | 0 No |
Answer / test
semaphores helps is a varible which is used to protect the shared data .hence avoiding the coruption of data by the threads acting simultaniously..
| Is This Answer Correct ? | 7 Yes | 4 No |
What is the value of y in the following code? x=7;y=0; if(x=6) y=7; else y=1;
Can we declare function inside main?
What is a stream water?
What are void pointers in c?
#include<stdio.h> { printf("Hello"); } how compile time affects when we add additional header file <conio.h>.
write a c prog for removing duplicate character from an array and sorting remaining elements using a single array
What is the difference between array and pointer?
helllo sir give me some information of the basic information the c as printf ,scanf , %d ,%f and why is the main use of these.
Explain spaghetti programming?
Why is not a pointer null after calling free?
Should I learn c before c++?
write a program in c language to print your bio-data on the screen by using functions.