51.
What will be the output of the following C++ code?
#include <iostream>  
using namespace std;
class A{
	A(){
		cout<<"Constructor called";
	}
};
int main(int argc, char const *argv[])
{
	A a;
	return 0;
}

52.
What will be the output of the following C++ code?
#include <iostream>  
using namespace std;
class A{
public:
	int a;
	A(){
		cout<<"Constructor called";
	}
};
int main(int argc, char const *argv[])
{
	A *a1 = (A*)malloc(sizeof(A));
	return 0;
}

54.
What will be the output of the following C++ code?
#include <iostream>  
using namespace std;
class A{
 
public:
	A(){
		cout<<"Constructor called";
	}
};
int main(int argc, char const *argv[])
{
	A *a;
	return 0;
}

55.
What will be the output of the following C++ code?
#include <iostream>  
using namespace std;
class A{
public:
	int a;
	A(int a=0){
		this->a = a;
	}
};
int main(int argc, char const *argv[])
{
	A a1, a2(10);
	cout<<a2.a;
	return 0;
}

56.
What will be the output of the following C++ code?
#include <iostream>  
using namespace std;
class A{
public:
	int a;
	A(){
		cout<<"Constructor called";
	}
} a;
int main(int argc, char const *argv[])
{
	return 0;
}

57.
What will be the output of the following C++ code?
#include <iostream>
#include <string>
using namespace std;
class A{
	mutable int a;
public:
	A(){
		cout<<"A's Constructor called\n";
	}
	~A(){
		cout<<"A's Destructor called\n";
	}
};
 
class B{
	static A a;
public:
	B(){
		cout<<"B's Constructor called\n";
	}
	~B(){
		cout<<"B's Destructor called\n";
	}
};
 
A B::a;
 
int main(int argc, char const *argv[])
{
	return 0;
}

58.
What will be the output of the following C++ code?
#include <iostream>  
using namespace std;
class A{
public:
	int a;
	A(int a){
		this->a = a;
	}
};
int main(int argc, char const *argv[])
{
	A a1, a2(10);
	cout<<a2.a;
	return 0;
}

59.
What will be the output of the following C++ code?
#include <iostream>
#include <string>
using namespace std;
class A{
	mutable int a;
public:
	A(){
		cout<<"A's default constructor called\n";
	}
	A(const A& a){
		cout<<"A's copy Constructor called\n";
	}
};
class B{
	A obj;
public:
	B(){
		cout<<"B's Constructor called\n";
	}
};
int main(int argc, char const *argv[])
{
	B b1;
	B b2;
}

60.
Why constructors are efficient instead of a function init() defined by the user to initialize the data members of an object?