Should a constructor be public or private?


No Answer is Posted For this Question
Be the First to Post Answer

Post New Answer

More C++ General Interview Questions

whats the size of class EXP on 32 bit processor? class EXP { char c1; char c2; int i1; int i2; char *ptr; static int mem; };

5 Answers   Huawei,


Is swift faster than c++?

0 Answers  


Difference between a copy constructor and an assignment operator.

0 Answers  


What is encapsulation in c++?

0 Answers  


What is the difference between #define debug 0 and #undef debug?

0 Answers  






How do you clear a buffer in c++?

0 Answers  


What is the maximum combined length of command line arguments including the space between adjacent arguments?

0 Answers  


What is a class template in c++?

0 Answers  


Why namespace is used in c++?

0 Answers  


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

0 Answers   HAL,


What happens when a function throws an exception that was not specified by an exception specification for this function?

1 Answers  


class basex { int x; public: void setx(int y) {x=y;} }; class derived : basex {}; What is the access level for the member function "setx" in the class "derived" above? a) private b) local c) global d) public e) protected

3 Answers   Quark,


Categories