Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Difference between Constructors and static constructors?

Answer Posted / venkataramakrishna. danduri

The main thing is the constructoe can't be Static, int or
any other data type. It will simpley throws a error
messgae. It is just to confuse the candidate.

Example:
class A
{
public:
static A(){ a = 0;}
int a;
};

void main()
{
A a;
}

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why is "using namespace std;" considered bad practice?

1091


What is the benefit of c++?

1125


What are c++ templates used for?

1134


What happens if a pointer is deleted twice?

1268


How does com provide language transparency?

1004


what are Access specifiers in C++ class? What are the types?

1220


What is #include math h in c++?

1073


How many namespaces are there in c++?

1071


What is null pointer and void pointer?

1068


Which operator cannot overload?

1042


Differentiate between realloc() and free().

1041


Difference between an inspector and a mutator

1332


Write is a binary search tree? Write an algo and tell complexity?

1020


What is #include ctype h in c++?

1161


Difference between pointer to constant and constant pointer to a constant. Give example.

1110