#include <bits/stdc++.h>
int gcd(int a, int b) {
  if (a < b) {
    int c = a;
    a = b;
    b = c;
  }
  int r;
  while (b) {
    r = a % b;
    a = b;
    b = r;
  }
  return a;
}
int main() {
  int x, y, a, b, n, m, x1, y1, x2, y2, dx, dy;
  scanf("%d%d%d%d%d%d", &n, &m, &x, &y, &a, &b);
  int k = 0;
  int g = gcd(a, b);
  a /= g;
  b /= g;
  while ((k + 1) * a <= n && (k + 1) * b <= m) {
    k++;
  }
  dx = k * a;
  dy = k * b;
  x1 = x - (dx + 1) / 2;
  y1 = y - (dy + 1) / 2;
  x2 = x + dx / 2;
  y2 = y + dy / 2;
  if (x1 < 0) {
    x1 = 0;
    x2 = dx;
  }
  if (x2 > n) {
    x2 = n;
    x1 = n - dx;
  }
  if (y1 < 0) {
    y1 = 0;
    y2 = dy;
  }
  if (y2 > m) {
    y2 = m;
    y1 = m - dy;
  }
  printf("%d %d %d %d\n", x1, y1, x2, y2);
  return 0;
}
