What is C#.NET Generics?

 Posted by Tripati_tutu on 12/22/2010 | Category: C# Interview questions | Views: 19823 | Points: 40
Answer:

When the C#.NET Generics are instantiated, then the CLR compiles and stores the information related to the generic types that is it refers to the location in memory of the reference type to which it is bound for all the instances. Here the classes and methods can treat the values of different types uniformly.

The main purpose of using this is to facilitate type safety, improves performance and reduces code. It also promotes the usage of parameterized types in an application.


Asked In: Many Interviews | Alert Moderator 

Comments or Responses

Posted by: SheoNarayan on: 6/14/2011 | Points: 10

Login to post response