#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int c, d, x, y, a, b;
  cin >> a >> b >> x >> y >> c >> d;
  if (c == 0 and d == 0) {
    if ((a == x and b == y) or (a == -x and b == -y) or (a == y and b == -x) or
        (a == -y and b == x))
      cout << "YES" << endl;
    else
      cout << "NO" << endl;
    return 0;
  }
  bool possible = false;
  long long int X = x, Y = y;
  if ((c * (x - a) + d * (y - b)) % (c * c + d * d) == 0 and
      (d * (x - a) - c * (y - b)) % (c * c + d * d) == 0)
    possible = true;
  x = -Y, y = X;
  if ((c * (x - a) + d * (y - b)) % (c * c + d * d) == 0 and
      (d * (x - a) - c * (y - b)) % (c * c + d * d) == 0)
    possible = true;
  x = -X, y = -Y;
  if ((c * (x - a) + d * (y - b)) % (c * c + d * d) == 0 and
      (d * (x - a) - c * (y - b)) % (c * c + d * d) == 0)
    possible = true;
  x = Y, y = -X;
  if ((c * (x - a) + d * (y - b)) % (c * c + d * d) == 0 and
      (d * (x - a) - c * (y - b)) % (c * c + d * d) == 0)
    possible = true;
  if (possible)
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
}
