The following solution has a major flaw. The XtangoAnimator class in the XtangoAnimation subdirectory of the lib directory can be used to animate the dining philosophers. Animated Dining Philosophers. Fix any race conditions you find. Printing W, X, Y, and Z Look in some operating systems books for semaphore exercises and write the solutions in Java.
Examples are classical problems like the cigarette smokers and the bakery.
Modify the dining philosophers server so that two philosophers cannot collaborate to starve the one between them. Modify the readers and writers database so that readers cannot starve writers. Unidirectional TSP Animate one or more of these programs.