#include <bits/stdc++.h>
using namespace std;
int gcd(int a, int b) { return b == 0 ? a : gcd(b, a % b); }
int test = 0;
int main() {
  int n, m, x, y, a, b;
  while (~scanf("%d%d%d%d%d%d", &n, &m, &x, &y, &a, &b)) {
    int t = gcd(a, b);
    a /= t;
    b /= t;
    t = min(n / a, m / b);
    int nn = t * a;
    int mm = t * b;
    if (test) printf("%d %d\n", nn, mm);
    int tn = (nn + 1) / 2, tm = (mm + 1) / 2;
    if (test) printf("%d %d\n", tn, tm);
    int x1 = max(x - tn, 0);
    int y1 = max(y - tm, 0);
    x1 = min(x1, n - nn);
    y1 = min(y1, m - mm);
    printf("%d %d %d %d\n", x1, y1, x1 + nn, y1 + mm);
  }
  return 0;
}
