#include<cstdio>
#include<cstdlib>
using namespace std;
int main(){
	
	double xA,yA,xB,yB,xC,yC,xD,yD;
	
	while(scanf("%lf%lf%lf%lf%lf%lf%lf%lf",&xA,&yA,&xB,&yB,&xC,&yC,&xD,&yD) != EOF){
		
		double P,Q;
		double a,b,c,d;
		bool f = 0;
		
		a = (yA-yB);
		b = (xA-xB);
		c = (yC-yD);
		d = (xC-xD);
		
		if(a == 0 && d == 0 || b == 0 && c == 0){
			puts("YES");
			f = 1;
		}
		
		if(f == 0){
			P = a / b;
			Q = c / d;
			
			(P*Q == -1.0) ? puts("YES") : puts("NO");
			
		}
	}
	
	return 0;
}