#include <iostream>
#include <cmath>

using namespace std;

int main() {
	double xa, ya, xb, yb, xc, yc, xd, yd;
	while (cin >> xa >> ya >> xb >> yb >> xc >> yc >> xd >> yd) {
		double b1x, b1y, b2x, b2y;
		b1x = xb-xa;
		b1y = yb-ya;
		b2x = xd-xc;
		b2y = yd-yc;
		if (fabs(b1x*b2x+b1y*b2y) <= 0.00000000001) {
			cout << "YES" << endl;
		} else {
			cout << "NO" << endl;
		}
	}
	return 0;
}