编程第九十一天

c++ 动态实现顺序表

template <class T>class Vector{

private: T * _data;  

int _siae;

int _capacity;

public:

Vector():

_siae(0)

,_cappacity(0)

,_data(new T[_cappacity])// 实现动态增容  

{}};

猜你喜欢

转载自blog.csdn.net/imezreal/article/details/72846928