#include<cmath>
#include<cstdio>
#include<vector>

#define	EPS		1e-9
#define	pb(a)	push_back(a);

using namespace std;

class Point{
public:
	double x,y;
	Point(){}
	Point(double xx,double yy) : x(xx),y(yy){}
};

class Line : public vector<Point>{
public:
	Line(const Point &a,const Point &b){
		pb(a);
		pb(b);
	}
};

Point &operator -=(Point &a,const Point &b)
{
	a.x-=b.x;
	a.y-=b.y;
	return a;
}

Point operator -(const Point &a,const Point &b)
{
	Point c=a;
	c-=b;
	return c;
}

double dot(const Point &a,const Point &b)
{
	return a.x*b.x+a.y*b.y;
}

bool orthogonal(const Line &l,const Line &m)
{
	return abs(dot(l[1]-l[0],m[1]-m[0]))<EPS;
}

int main()
{
	for(Point a,b,c,d;~scanf("%lf%lf%lf%lf%lf%lf%lf%lf",&a.x,&a.y,&b.x,&b.y,&c.x,&c.y,&d.x,&d.y);){
		Line l(a,b),m(c,d);
		puts(orthogonal(l,m)?"YES":"NO");
	}
	return 0;
}