NVIDIA interview question

Coding round to synchronize actions to FIFO queue