#include <bits/stdc++.h>
using namespace std;
int gcd(int x, int y) {
  if (y == 0) return x;
  return gcd(y, x % y);
}
int main() {
  int n, m, x, y, a, b;
  cin >> n >> m >> x >> y >> a >> b;
  int d = gcd(a, b);
  a /= d;
  b /= d;
  int X = min(n / a, m / b);
  int A = X * a, B = X * b;
  int p = min(n - A, max(0, x - (A + 1) / 2)),
      q = min(m - B, max(0, y - (B + 1) / 2));
  cout << p << " " << q << " " << p + A << " " << q + B << endl;
}
