A take on the Berkeley classical H2O molecule creation problem with semaphores implemented in C.