#include
#include
using namespace std;
class point {
int x,y;
public:
point(int xx=0,int yy=0) {x=xx; y=yy;cout<<111<
int gety() {return y;}
};
class line{
point p1,p2;
double len;
public:
line(int i,int j,int a,int b):p1(i,j),p2(a,b)
{
int m,n;
m=p1.getx()-p2.getx();
m=p1.gety()-p2.gety();
len=sqrt(m*m+n*n);
cout<<222<
line(point xp1,point xp2):p1(xp1),p2(xp2)
{
int m,n;
m=p1.getx()-p2.getx();
n=p1.gety()-p2.gety();
len=sqrt(m*m+n*n);
cout<<333<
double getlen() {return len;}
};
main()
{
line line1(0,0,3,4); //变量不能和类型同名
cout<
line line2(p1,p2); //原先line写错
cout<