#include <iostream>
using namespace std;
class P{
private:
int* i=new int(5);
public:
~P(){delete i;};
int a(){return *i;};
};
void f(P p){};
int main()
{
P a;
cout<<a.a()<<endl;
f(a);
cout<<a.a()<<endl;
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgoKdXNpbmcgbmFtZXNwYWNlIHN0ZDsKCmNsYXNzIFB7CiAgICBwcml2YXRlOgogICAgaW50KiBpPW5ldyBpbnQoNSk7CiAgICBwdWJsaWM6CiAgICB+UCgpe2RlbGV0ZSBpO307CiAgICBpbnQgYSgpe3JldHVybiAqaTt9Owp9OwoKdm9pZCBmKFAgcCl7fTsKCmludCBtYWluKCkKewogICAgUCBhOwogICAgY291dDw8YS5hKCk8PGVuZGw7CiAgICBmKGEpOwogICAgY291dDw8YS5hKCk8PGVuZGw7CiAgICByZXR1cm4gMDsKfQ==