What are Generics? Where do we use them.
Answers were Sorted based on User's Feedback
Answer / ritz
Generics was introduced in Framework 2.0
With generics we can have typed classes. While defining
class we simply give placeholders and when we create
objects of that class we declare the placeholder to be of
some type(like int, double, string, etc.) and from that
point on our object gets bind to that type only.
Is This Answer Correct ? | 8 Yes | 0 No |
Answer / rakesh kumar kunchala
Generics are used to have Typed Arrays.
Ex: if we have define that an array is confined to products.
if we push objects of product into array it accepts.
if we push employee objects into this array it will show
error . since the type of the array is product.
Is This Answer Correct ? | 9 Yes | 3 No |
How many namespaces are in .net version 1.1?
What is new in .net core?
What are situations when you register .NET assembly in GAC ?
What is the use of activex control in .net?
How to manage pagination in a page using .net?
Different levels of priority provided by .net.
How can you instantiate a tuple?
what is the use of stored procedure which has only one select statement over simple select statment query ? Why to write a stored procedure then ?
What?s a Windows process?
What is boxing?
What is your observations between vb.net and vc#.net?
What is the best way to crack the certification?