templte <typename T,
template <rypename ELEM,typename ALLOC=std::allocator<ELEM> >
class CONT=std::deque>
class Stack{
public:
void push(t const&);
void pop();
T top()const;
bool empty()const{
return elems.empty();
}
template <typename T2,
template<typename ELEM2,
typename=std::allootor<ELEM2>
> class CONT2>
private:
CONT<T> elems;
};
template <typename T,template <typename,typename> class CONT>
void Stck<T,CONT>::push(T const& elem){
elems.push_back(elem);
}
...
没有写全
越学越 看不懂了
越不自信了