#include <iostream>
using namespace std;

int main() {
    double x[4], y[4];
    while (cin >> x[0] >> y[0]) {
        for (int i = 1; i < 4; i++) {
            cin >> x[i] >> y[i];
        }
        double v1[2] = {x[0] - x[1], y[0] - y[1], };
        double v2[2] = {x[2] - x[3], y[2] - y[3], };

        if (v1[0] * v2[0] + v1[1] * v2[1] == 0) {
            cout << "YES" << endl;
        } else {
            cout << "NO" << endl;
        }
    }
}