Something
public text v1 · immutable class Program
{
static void Main(string[] args)
{
List<int> list = new List<int> { 1, 2, 3, 4, 5 };
ex<int>(list);
}
public static void ex<T>(IList<T> list)
{
int? nbr;
if (list as List<int> != null)
nbr = (list[0] as int?) + (list[1] as int?);
}
}