Template function in C# - Return Type?
- by LifeH2O
It seems that c# does not support c++ like templates.
template <class myType>
myType GetMax (myType a, myType b) {
return (a>b?a:b);
}
I want my function to have return type based on its parameters, how can i achieve this in c#? How to use templates in C#