#include <bits/stdc++.h>
using namespace std;
inline int gcd(int a, int b) { return a == 0 ? b : gcd(b % a, a); }
int main() {
  int n, m;
  cin >> n >> m;
  int x, y, a, b;
  cin >> x >> y >> a >> b;
  int g = gcd(a, b);
  a /= g;
  b /= g;
  int coeff = min(n / a, m / b);
  int width = coeff * a;
  int height = coeff * b;
  int lx = x - (width + 1) / 2;
  int ly = y - (height + 1) / 2;
  lx = max(0, lx);
  ly = max(0, ly);
  lx = min(lx, n - width);
  ly = min(ly, m - height);
  cout << lx << ' ' << ly << ' ' << lx + width << ' ' << ly + height << endl;
  return 0;
}
