Microsoft interview question

Implement a counting semaphore using only binary mutexes