#include <iostream>
using namespace std;
class C {
public:
int a;
C () {}
C (const C& c) {
cout << "copy constructor";
}
};
C* ptr;
C func(){
C c;
c.a = 132;
ptr = &c;
return c;
}
int main() {
C c1 = func();
(*ptr).a = 34;
cout << c1.a << endl;
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKY2xhc3MgQyB7CnB1YmxpYzoKCWludCBhOwoJQyAoKSB7fQoJQyAoY29uc3QgQyYgYykgewoJCWNvdXQgPDwgImNvcHkgY29uc3RydWN0b3IiOwoJfQp9OwoKQyogcHRyOwoKQyBmdW5jKCl7CglDIGM7CgljLmEgPSAxMzI7CglwdHIgPSAmYzsKCXJldHVybiBjOwp9CgppbnQgbWFpbigpIHsKICAgIEMgYzEgPSBmdW5jKCk7CiAgICAoKnB0cikuYSA9IDM0OwogICAgY291dCA8PCBjMS5hIDw8IGVuZGw7CglyZXR1cm4gMDsKfQoKCgo=