#include <bits/stdc++.h>
using namespace std;

#define rep(i,n) for(int i=0;i<(n);++i)
#define loop for(;;)
#define trace(var) cerr<<">>> "<<#var<<" = "<<var<<endl;
#define inf (1e9)
#define eps (1e-9)

template<class S, class T> inline
ostream& operator<<(ostream&os, pair<S,T> p) {
  return os << '(' << p.first << ", " << p.second << ')';
}

template<class S, class T, class U> inline
ostream& operator<<(ostream&os, tuple<S,T,U> t) {
  return os << '('
    << get<0>(t) << ", "
    << get<1>(t) << ", "
    << get<2>(t) << ')';
}

template<class T> inline
ostream& operator<<(ostream&os, vector<T> v) {
  if (v.size() == 0) { return os << "(empty)"; }
  os << v[0];
  for (int i=1, len=v.size(); i<len; ++i) os << ' ' << v[i];
  return os;
}

template<class T> inline
istream& operator>>(istream&is, vector<T>&v) {
  rep (i, v.size()) is >> v[i];
  return is;
}

int main() {
  long
  double x0,y0,x1,y1,x2,y2,x3,y3;
  while (cin>>x0>>y0>>x1>>y1>>x2>>y2>>x3>>y3) {
    long
    double dx0 = x1 - x0,
           dy0 = y1 - y0,
           dx1 = x3 - x2,
           dy1 = y3 - y2;
    // trace((dx0 * dx1 + dy0 * dy1));
    // trace(abs(dx0 * dx1 + dy0 * dy1));
    // trace(labs(dx0 * dx1 + dy0 * dy1));
    string str =
      (abs(dx0 * dx1 + dy0 * dy1) < 1e-13)
      ? "YES"
      : "NO";
    cout << str << endl;
  }

  return 0;
}