MathWorks Interview Question

Template class (c++)