say i have a list of numbers in an array created by a class template
Code:
#include <iostream>
#include <fstream>
#include <string>
#include <iomanip>
using namespace std;
const int CAPACITY = 20;
template <class T>
class A
{
public:
A();
~A();
operator+(dont know what goes here)
private:
int *number;
int count;
}
template<class T>
A<T>::A(){
number=new string[CAPACITY];
//more code that fills in the array here
//count increases as array is filled
}
template<class T>
A<T>::operator+(?){
}
int main(){
A<T> object;
object+454556+5644;//adds 454556 and 5644 to the array
or can you not do this