I'm beginner on C and checking this code
int is_finished()
{
    int counter = 0;
    sem_wait(&global_mutex);
    counter = NotEatenCount;
    sem_post(&global_mutex);    
    return counter==0;
}
the function should return an integer. What does return counter==0 means in here? It looks like:
if(counter==0){
  return true;
}
else{
 return false;
}
 
     
     
     
     
     
     
    