// Circular Queue, without wasting an array of space
#include <iostream>
using namespace std;
template <typename T>
class Queue
{
private:
int _rear, _front;
int _max_size;
int *arr;
public:
Queue(int s)
{
_front = _rear = -1;
_max_size = s;
arr =
循环队列,不浪费一个数组空间
最新推荐文章于 2022-06-13 09:48:25 发布