At a geometry lesson Gerald was given a task: to get vector B out of vector A. Besides, the teacher permitted him to perform the following operations with vector А:

  * Turn the vector by 90 degrees clockwise.
  * Add to the vector a certain vector C.



Operations could be performed in any order any number of times.

Can Gerald cope with the task?

Input

The first line contains integers x1 и y1 — the coordinates of the vector A ( - 108 ≤ x1, y1 ≤ 108). The second and the third line contain in the similar manner vectors B and C (their coordinates are integers; their absolute value does not exceed 108).

Output

Print "YES" (without the quotes) if it is possible to get vector B using the given operations. Otherwise print "NO" (without the quotes).

Examples

Input

0 0
1 1
0 1


Output

YES


Input

0 0
1 1
1 1


Output

YES


Input

0 0
1 1
2 2


Output

NO
#include <bits/stdc++.h>
using namespace std;
int Ax, Ay, Bx, By, Cx, Cy;
long long det(int a, int b, int c, int d) {
  return (long long)a * d - (long long)b * c;
}
int gcd(int a, int b) {
  if (a == 0) return b;
  if (b == 0) return a;
  return gcd(b, a % b);
}
bool solve2(int a, int b, int c) {
  if (a == 0 && b == 0) return c == 0;
  if (a == 0) return c % b == 0 && c / b >= 0;
  if (b == 0) return c % a == 0 && c / a >= 0;
  int d = gcd(a, b), q;
  if (c % d != 0) return false;
  if (a < 0) {
    c = -c;
    b = -b;
  }
  if (b > 0)
    for (q = 0; c - b * q >= 0; q++)
      if ((c - q * b) % a == 0 && (c - q * b) / a >= 0)
        return true;
      else
        return true;
  return false;
}
bool solve(int a1, int b1, int c1, int a2, int b2, int c2) {
  long long D = det(a1, b1, a2, b2), D1 = det(a1, c1, a2, c2),
            D2 = det(c1, b1, c2, b2);
  if (D) return (D1 % D == 0 && D2 % D == 0 && D1 / D >= 0 && D2 / D >= 0);
  return solve2(a1, b1, c1);
}
bool go(int cx, int cy, int dx, int dy) {
  return solve(cx, dx, Bx - Ax, cy, dy, By - Ay);
}
int main(int argc, char *argv[]) {
  scanf("%d%d%d%d%d%d", &Ax, &Ay, &Bx, &By, &Cx, &Cy);
  int i, j;
  for (i = 0; i < 4; i++) {
    swap(Ax, Ay);
    Ax = -Ax;
    if (Cx == 0 && Cy == 0) {
      if (Ax == Bx && Ay == By) {
        printf("YES\n");
        return 0;
      }
    } else {
      for (j = 0; j < 4; j++) {
        swap(Cx, Cy);
        Cx = -Cx;
        if (go(Cx, Cy, -Cy, Cx)) {
          printf("YES\n");
          return 0;
        }
      }
    }
  }
  printf("NO\n");
  return 0;
}
