#include #include using namespace std; template class Cell{ public: Cell(T val): value(val) {} T& getValue(){ return value; } void setValue(T val){ value = val; } private: T value; }; int main(){ Cell c(10); cout << "An int: " << c.getValue() << endl; Cell stringCell("a string"); cout << "A string: " << stringCell.getValue() << endl; vector v; v.push_back(10); Cell > vectorCell(v); cout << "A vector: " << vectorCell.getValue().at(0) << endl; }