An attempt to solve the "Dining Philosophers" problem in C++