C++. class. , . . class _ : _ { // , . private: // , . protected: // public: // . } _;_ . _ , . _ _, . . _ . "" (.). "" (->) . , putinfo() ob "", show() "". struct cl_type{ int x; float f; public: void putinfo (int a, float t) { x - a; f - t;} void show () { cout << a << ' ' << f << endl;} }; cl_type ob, *p; ob.putinfo (10, 0.23); p = &ob; // ob p p->show(); // ob . . . . class Base{ class nested{ public: nested(); }; public: Base() {...} }; Base :: nested :: nested() { //... } |