构造函数与析构函数
#include<iostream>
using namespace std;
class person{
public:
//构造函数
person(){
cout<<"person构造函数的调用"<<endl;
}
~person(){
cout<<"person析构函数的调用"<<endl;
}
};
void test1(){
person p;
cout<<1<<endl;
}
int main(){
test1();
return 0;
}