Wednesday, September 1, 2010

why all c++ program must have default constructor?

a defaulft constructor is created that takes no parameters
and does nothing.that takes no arguments but sets up your
object as required.

A defaulft constructor ,but by no convention so is any
constructor that takes parameters ,this is can be a bit confusing ,but is usually clear from context which one is meant.


A default constructor is not made by the compiler.so if u want a constructor that takes no parameters ,and u,ve created any others constructors ,u must make the default constructor urself.

"that if u make any constructor at all."

No comments:

Post a Comment