Empty constructor or no constructor

Posted by Ram on Stack Overflow See other posts from Stack Overflow or by Ram
Published on 2010-06-03T06:30:43Z Indexed on 2010/06/03 6:34 UTC
Read the original article Hit count: 470

Filed under:
|

Hi,

I think it is not mandatory to have a default constructor in a class (C#).

So in that situation shall I have a empty constructor in the class or I can skip it?

Is it a best practice to have a default empty constructor?

Class test
{
test()
{

}
        ......
}

or

Class test
{
            ......
}

© Stack Overflow or respective owner

Related posts about c#

Related posts about best-practices