#include <iostream>
#include <cstdio>
#include <vector>
#include <cstdlib>
#include <cmath>
using namespace std;

double eps=1.0e-5;
int main(){
  double x1,x2,x3,x4,y1,y2,y3,y4;
  while(scanf("%lf %lf %lf %lf %lf %lf %lf %lf",&x1,&y1,&x2,&y2,&x3,&y3,&x4,&y4)==8){
    double vec1_x,vec2_x,vec1_y,vec2_y;
    vec1_x=x2-x1;
    vec1_y=y2-y1;
    vec2_x=x4-x3;
    vec2_y=y4-y3;
    if(fabs(vec2_y*vec1_y + vec2_x*vec1_x)<eps)printf("YES\n");
    else printf("NO\n");
  }
  return 0;
}