The purpose of this assignment is to write an implementation of a semaphore using the mutex and condition variable provided by the POSIX thread library, and then to use semaphores to solve a common synchronization problem.