#include <iostream>
#include <cmath>

using namespace std;

constexpr double EPS = 1.0e-6;

int main()
{
    double xa, ya, xb, yb, xc, yc, xd, yd;

    while (cin >> xa >> ya >> xb >> yb >> xc >> yc >> xd >> yd) {
        double dot = (xb - xa) * (xd - xc) + (yb - ya) * (yd - yc);

        cout << ((abs(dot) < EPS)? "YES": "NO") << endl;
    }

    return 0;
}