Implement an array-based queue in C++