Apple interview question

write a ring-buffer

Interview Answer

Anonymous

12 Aug 2019

I used a static array, with size 1K (power of 2), and r/w indexes. I was a little sloppy with my index manipulations, and conditions for full/empty RB's. Google any article about this, and just slam down the code.