#include <bits/stdc++.h>
using namespace std;
long long int gcd(long long int a, long long int b) {
  if (a == b)
    return a;
  else if (a == 1 || b == 1)
    return 1;
  return a > b ? gcd(a - b, b) : gcd(a, b - a);
}
int main() {
  long long int n, m, x, y, a, b, mul, diffx, diffy, l, r, x1, x2, y1, y2;
  double diff;
  long long int g;
  cin >> n >> m >> x >> y >> a >> b;
  g = gcd(a, b);
  a = a / g;
  b = b / g;
  mul = min(n / a, m / b);
  diffx = a * mul;
  diffy = b * mul;
  l = x - diffx / 2;
  l = diffx & 1 ? l - 1 : l;
  r = y - diffy / 2;
  r = diffy & 1 ? r - 1 : r;
  if (l < 0)
    x1 = 0;
  else
    x1 = l;
  x2 = x1 + diffx;
  if (x2 > n) {
    x2 = n;
    x1 = x2 - diffx;
  }
  if (r < 0)
    y1 = 0;
  else
    y1 = r;
  y2 = y1 + diffy;
  if (y2 > m) {
    y2 = m;
    y1 = y2 - diffy;
  }
  cout << x1 << " " << y1 << " " << x2 << " " << y2;
  return 0;
}
