#include<iostream>
#include<complex>
using namespace std;
#define dff 1e-9
int main(){
  complex<double> a,b,c,d;
  while(cin >>a.real()>>a.imag()>>b.real()>>b.imag()>>c.real()>>c.imag()>>d.real()>>d.imag()){
    complex<double> vab,vcd;
    vab = a-b;
    vcd = c-d;
    double v = vab.real()*vcd.real()+vab.imag()*vcd.imag();
    if(v<dff && v>=-dff) cout <<"YES"<<endl;
    else cout <<"NO"<<endl;
  }
  return 0;
}