#include <iostream>
using namespace std;

double x[4], y[4];

int main() {
    while(cin>>x[0]>>y[0]) {
        for(int i=1; i<4; i++)
            cin >> x[i] >> y[i];

        double vab1 = x[0] - x[1];
        double vab2 = y[0] - y[1];
        double vcd1 = x[2] - x[3];
        double vcd2 = y[2] - y[3];

        if(vab1*vcd1 + vab2*vcd2 == 0)
            cout << "YES" << "\n";
        else
            cout << "NO" << "\n";
    }


    return 0;
}