#include "iostream"
using namespace std;
class point
{int x,y;
public:
point(int x1=0,int y1=0):x(x1),y(y1){}
friend ostream& operator<<(ostream&, const point&);
friend istream& operator>>(istream&,point&);
};
ostream& operator<<(ostream& out, const point& src)
{ cout<<'<'<<src.x<<','<<src.y<<'>';
return out;
}
istream& operator>>(istream& in,point& target)
{ cin>>target.x>>target.y;
return in;
}
int main()
{point a(1,2);
cout<<"请输入:"<<endl;
cin>>a;
cout<<a;
return 0;
}
out和in编译器认识吗?cout,cin