#include<iostream>
#include<cmath>
using namespace std;
int main() {
	double a, b, c, d, e, f, g, h;
	while (cin >> a >> b >> c >> d >> e >> f >> g >> h){
		if (a == c || e == g) {
			if (a == c&&f == h)cout << "YES\n";
			else if (b == d&&e == g)cout << "YES\n";
			else cout << "NO\n";
		}
		else{
			double k1 = (d - b) / (c - a);
			double k2 = (h - f) / (g - e);
			if (k1*k2 == -1)cout << "YES\n";
			else cout << "NO\n";
		}
	}
}