#include <iostream>
using namespace std;
class T
{
public:
T(){
cout<<"T::T()"<<endl;
}
T(T& a){
cout<<"T::T(T&)"<<endl;
}
~T(){
cout<<"T::~T()"<<endl;
}
int i;
};
void func(T t)
{
cout<<"func() "<<t.i <<endl;
}
void func2(T& t)
{
cout<<"func() "<<t.i <<endl;
}
void main()
{
T tt;
func(tt);
func2(tt);
}