fork download
  1. using System;
  2. using System.Collections.Generic;
  3.  
  4. public class Test
  5. {
  6. public static void Main()
  7. {
  8. // your code goes here
  9. var type = typeof(List<int>);
  10. Console.WriteLine(type.IsGenericType && type.GetGenericTypeDefinition() == typeof(List<>));
  11. }
  12. }
Success #stdin #stdout 0.01s 131648KB
stdin
Standard input is empty
stdout
True