<s>在A类中定义C类的指针*p，现在需要在B类中获取*p的值或地址，用什么办法？</s>
<s>C++ 以下方法，可以访问成员变量 1) get(）方法,也就是写个 public函数返回一个值 int get()const{return this->mx;}; 2）通过友元 直接取 3）访问属性设置为 public 可以直接 用 4）可以用过 out 参数传递 void get(int &x){return this->mx;}; 5）访问多个成员，也可以通过 public 方法（成员函数）访问</s>
