#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(-0.0000000001 < (yA-yB)*(yC-yD) + (xC-xD)*(xA-xB) &&
     (yA-yB)*(yC-yD) + (xC-xD)*(xA-xB) < 0.0000000001)
     cout << "YES" << endl;
      else cout << "NO" << endl;
   }
   return 0;
}