#include <vector>
#include <map>
#include <set>
#include <stack>
#include <queue>
#include <algorithm>
#include <numeric>
#include <utility>
#include <sstream>
#include <iostream>
#include <iomanip>
#include <cstdio>
#include <cmath>
#include <string>
#include <cstring>
#include <complex>
#include <ctime>
#include <cstdlib>

using namespace std;

inline int to_int(string s) {int v; istringstream sin(s); sin >> v; return v;}
template<class T> inline string to_str(T x) {ostringstream sout; sout << x; return sout.str();}

typedef long long ll;

int main()
{
	float x1, y1, x2, y2, x3, y3, x4, y4;

	while(scanf("%f%f%f%f%f%f%f%f",&x1 ,&y1 ,&x2 ,&y2 ,&x3 ,&y3 ,&x4 ,&y4) != EOF)
	{	
		if(( y2 == y1 && x3 == x4 )||(x1 == x2 && y3 == y4))
		{
			cout << "YES" << endl;
		}
		else if((y2-y1)/(x2-x1) * (y3-y4)/(x3-x4) == -1.0)
		{
			cout << "YES" << endl;
		}
		else
		{
			cout << "NO" << endl;
		}
	}
}