Hacker News new | past | comments | ask | show | jobs | submit login

I wouldn't call this a trick. This is a staple in the data structures books when they teach how to implement queues using arrays. The same approach can be extended to implementing circular and double ended queues as well.



Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: