#include <iostream> using namespace std; class A { private: A(int x,int y) { } }; class B:public A { }; int main() { cout << "Hello world!" << endl; B c; return 0; }
#include <iostream> using namespace std; class A { public: A(int ,int ) { cout <<"construct"<<endl; } private: A() { } }; class B:public A { }; int main() { cout << "Hello world!" << endl; A d(0,0); B c; return 0; }
#include <iostream> using namespace std; class A { private: static void f() { A(); } A() { } }; class B//:public A { public: B() { cout<<"B constrcut"<<endl; } }; int main() { cout << "Hello world!" << endl; //A d(0,0); A a; //B c; return 0; }