Home » C++ Programming » Constructors and Destructors

Which of the following statement is correct about the program given below? #include class Tab { int x; public: Tab(); ~Tab(); void Show() const; }; Tab::Tab() { x = 25; } void Tab::Show() const { cout<< x; } int main() { Tab objB; objB.Show(); return 0; }

Correct Answer: The program will report compile time error.

← Previous Question Next Question→

More Questions from Constructors and Destructors

Discussion & Comments

No comments yet. Be the first to comment!
Join Discussion