I'm coming from C and I'm picking up C++ pretty fast. I just have a small question about function templates. In my book it gives the following function template:
My question deals with the head of the template. The book says that inside the brackets the formal type parameters are preceded either by typename or class (as it is in the example).
template < class T >
T maximum(T value1, T value2, T value3)
T max = value1;
if (value2 > max)
max = value2;
My question is does it matter which? And if it does matter, when do I use one or the other?