#include <iostream>
#include <cstdio>
#include <vector>
#include <list>
#include <algorithm>
#include <cmath>
#include <stack>
#include <map>
#include <numeric>
using namespace std;

#define REP(i,n) for(int (i)=0; (i)<(n); (i)++)
#define FOR(i,a,b) for(int (i)=(a); (i)<(b); (i)++)
#define PUSH(n,v) for(int i=0; i<(n); i++) {int j; cin >> j; v.push_back(j);}
#define ALL(v) v.begin(), v.end()
#define print(s) cout << (s) << endl

const double EPS = 1e-9;

bool equal(double a) {
    return abs(a) < EPS*100;
}

int main() {
    double xa,ya,xb,yb,xc,yc,xd,yd;
    while(cin>>xa>>ya>>xb>>yb>>xc>>yc>>xd>>yd) {
        double AB, CD;
        AB = (xa-xb)/(ya-yb+EPS);
        CD = (xc-xd)/(yc-yd+EPS);
        if (equal(AB*CD+1) || (equal(AB) && !equal(CD)) || (equal(CD) && !equal(AB))) {
            cout << "YES" << endl;
        }else {
            cout << "NO" << endl;
        }
    }
    return 0;
}