#include <bits/stdc++.h>
using namespace std;
template <class T>
inline void OUTLN(T &arr, int len) {
  for (int i = 0; i < len; i++) cout << arr[i] << " ";
  cout << endl;
}
const double eps = 1e-9;
const double pi = acos(-1.0);
const int oo = 1000000000;
const int mod = 1000000007;
const double E = 2.7182818284590452353602874713527;
int n, m, x, y, a, b;
int gcd(int a, int b) { return b == 0 ? a : gcd(b, a % b); }
void doit(int &lf, int &rt, int &len, int &tot, int p) {
  if (len & 1) {
    if (p < tot - len / 2 && p > 0 + len / 2) {
      lf = p - len / 2 - 1;
      rt = lf + len;
    } else if (p >= tot - len / 2) {
      rt = tot;
      lf = tot - len;
    } else {
      lf = 0;
      rt = 0 + len;
    }
  } else {
    if (p <= tot - len / 2 && p >= 0 + len / 2) {
      lf = p - len / 2;
      rt = lf + len;
    } else if (p > tot - len / 2) {
      rt = tot;
      lf = tot - len;
    } else {
      lf = 0;
      rt = 0 + len;
    }
  }
}
int main() {
  cin >> n >> m >> x >> y >> a >> b;
  int g = gcd(a, b);
  a /= g;
  b /= g;
  int ds = min(n / a, m / b);
  int len = a * ds, hei = b * ds;
  int x1, y1, x2, y2;
  doit(x1, x2, len, n, x);
  doit(y1, y2, hei, m, y);
  printf("%d %d %d %d\n", x1, y1, x2, y2);
}
