thumbnail

Pisar-ctenar

Quiz by
Hralyb
Rate:
Last updated: May 14, 2025
You have not attempted this quiz yet.
First submittedMay 14, 2025
Times taken8
Average score100.0%
Report this quizReport
30:00
Enter answer here
0
 / 20 guessed
The quiz is paused. You have remaining.
Scoring
You scored / = %
This beats or equals % of test takers also scored 100%
The average score is
Your high score is
Your fastest time is
Keep scrolling down for answers and more stats ...
Hint
Answer
init
int readcount = 0;
 
semaphore mutex, wrt;
 
init(mutex,1);
 
init(wrt, 1);
pisar
do{
 
lock(wrt);
 
unlock(wrt);
 
}while(1);
ctenar
do{
 
lock(mutex);
Hint
Answer
 
readcount++;
 
if(readcount == 1)
 
lock(wrt);
 
unlock(mutex);
 
lock(mutex);
 
readcount--;
 
if(readcount == 0)
 
unlock(wrt);
 
unlock(mutex);
 
}while(1);
Save Your Stats
Your Next Quiz
Name all 50 states in the USA. Easy, right?
Can you name the countries with the highest GDP per capita?
Name the 20 cities ranked as the world's top financial centers according to the Global Financial Centres Index.
Drag the pin onto the correct country. Careful, though! Three wrong moves and the game ends.
Comments
No comments yet