I am trying to write a simple function which will take an arbitrary number of arguments and return the maximum out of them. It works for individual data types like integers, doubles etc. However, I do not want to write separate function for each data type, so I tried to create a function template, but it does not work.