Microsoft interview question

Write the code for the Producer-Consumer problem.