Explain constructor?

Answer Posted / ranjanatyagi

A constructor has the same name as class name.Constructor
has no return type.Constructor are used to initialize the
object.

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to create events for a control? What is custom events? How to create it?

534


What are immutable types in c#?

477


Define a strong name in .net?

533


What's the difference between abstraction and encapsulation?

451


Is inheritance possible in c sharp?

622






Explain the types of errors in c#?

475


What are extensions in c#?

528


In object oriented programming, how would you describe encapsulation in c#?

530


Which is faster iqueryable or ienumerable?

558


What is parsing? How to parse a date time string?

529


can you create a function in c# which can accept varying number of arguments

591


Which control cannot be placed in mdi?

521


Are c# generics the same as c++ templates?

490


What is the base class of all classes in c#?

499


What is a variable in c#?

464