Array implementation for queue