Constructors and Destructors - Programming

Q1:

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

A The program will print the output 25.

B The program will print the output Garbage-value.

C The program will report compile time error.

D The program will report runtime error.

ANS:A - The program will print the output 25.

No answer description is available. Let's discuss.