#include<iostream>
using namespace std;
int main() {
	double xa, ya, xb, yb, xc, yc, xd, yd;
	while (cin >> xa >> ya >> xb >> yb >> xc >> yc >> xd >> yd){
		if (xa == xb&&yc == yd || ya == yb&&xc == xd) { cout << "YES\n"; }
		else if ((ya - yb) / (xa - xb)*(yc - yd) / (xc - xd) == -1) { cout << "YES\n"; }
		else cout << "NO\n";
	}
}