#include <bits/stdc++.h>

using namespace std;

int main()
{
    while (1){
        double pt[8];
        for (int i = 0; i < 8; i++){
            if (scanf("%lf", pt + i) != 1) return (0);
        }
        
        double xAB = pt[2] - pt[0], yAB = pt[3] - pt[1],
               xCD = pt[6] - pt[4], yCD = pt[7] - pt[5];
        
        printf("%s\n", fabs(xAB * xCD + yAB * yCD) <= 1e-10 ? "YES" : "NO");
    }
    
    return (-1);
}