#include <iostream>
using namespace std;

int main(){

  double ax,ay,bx,by,cx,cy,dx,dy;

  while(cin >> ax >> ay >> bx >> by >> cx >> cy >> dx >> dy){
    double vxab = bx - ax;
    double vyab = by - ay;
    double vxcd = dx - cx;
    double vycd = dy - cy;
    if(vxab*vxcd + vyab*vycd < 1e-10 && vxab*vxcd + vyab*vycd > -(1e-10)) cout << "YES" << endl;
    else cout << "NO" << endl;
  }
  return 0;
}