#include <bits/stdc++.h>
int gcd(int a, int b) { return b == 0 ? a : gcd(b, a % b); }
int min(int a, int b) { return a < b ? a : b; }
int main() {
  int n, m, x, y, a, b, c, d, i, j, x1, y1, x2, y2, t;
  while (scanf("%d%d%d%d%d%d", &n, &m, &x, &y, &a, &b) != EOF) {
    c = gcd(a, b);
    a = a / c;
    b = b / c;
    t = min(n / a, m / b);
    if (t % 2 == 0) {
      t = t / 2;
      x1 = x - t * a;
      y1 = y - t * b;
      x2 = x + t * a;
      y2 = y + t * b;
    } else {
      t = t / 2;
      x1 = x - t * a;
      y1 = y - t * b;
      x2 = x + t * a;
      y2 = y + t * b;
      x1 = x1 - (a - a / 2);
      y1 = y1 - (b - b / 2);
      x2 = x2 + a / 2;
      y2 = y2 + b / 2;
    }
    if (x1 < 0) {
      t = x1;
      x1 = 0;
      x2 += -t;
    }
    if (y1 < 0) {
      t = y1;
      y1 = 0;
      y2 += -t;
    }
    if (x2 > n) {
      t = x2 - n;
      x2 = n;
      x1 -= t;
    }
    if (y2 > m) {
      t = y2 - m;
      y2 = m;
      y1 -= t;
    }
    printf("%d %d %d %d\n", x1, y1, x2, y2);
  }
}
