A prototypical generic method : Generic Method : Generics C# Source Code


Custom Search

C# Source Code » Generics » Generic Method »

 

A prototypical generic method









    



using System;

public class Starter{
    public static void Main(){
       MethodA<int>(20);
    }
    public static void MethodA<T>(T param) {
       Console.WriteLine(param.GetType().ToString());
    }

}

 

           
       
    
   
  
   







HTML code for linking to this page:

Follow Navioo On Twitter

C# Source Code

 Navioo Generics
» Generic Method