Thread-Safe Queue (Mutex + Condition Variable)

Asked at Belvedere Trading · Coding Questions · Difficulty: Medium

Implement a blocking, thread-safe FIFO queue for producer/consumer use, built on a mutex and a condition variable.

Loading the problem…