#include <cstdio>
#include <cstdlib>
#include <cmath>
#include <map>
#include <utility>
#include <set>
#include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <sstream>
#include <queue>
#include <cstring>
#include <functional>
#include <complex>

using namespace std;

#define REP(i,a,b) for((i)=(a);(i)<(int)(b);(i)++)
#define rep(i,n) REP(i,0,n)
#define foreach(itr,c) for(typeof((c).begin()) itr=(c).begin();itr!=(c).end();itr++)
template<class T> inline string toString(T x){ostringstream sout;sout<<x;return sout.str();}

#define EPS 1e-9
#define EQ(a,b) (abs((a)-(b)) < EPS)
typedef complex<double> P;
double dot(P a, P b){ return a.real()*b.real() + a.imag()*b.imag();}

int main(){
  int i,j,k,n;
  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){
    P ab((xB-xA),(yB-yA)), cd((xD-xC),(yD-yC));
    if(EQ(0,dot(ab,cd))) printf("YES\n");
    else printf("NO\n");
  }

  return 0;
}