template <class T>class Array { protected : T* data; int size; }; template<class T>class Stack : protected Array<T> { int top; public: Stack(){}; public: void Push(T x) {data[++top] = x;} }; Why it say '"data" was not declared in this scope' in Push? How can I fix this? When I delete each template<T>, it works normally. Is something wrong in my template?