#include <bits/stdc++.h>
using namespace std;
int gcd(int a, int b) { return b ? gcd(b, a % b) : a; }
int N, M, X, Y, A, B, CX, CY;
int main() {
  scanf("%d%d%d%d%d%d", &N, &M, &X, &Y, &A, &B);
  int p = gcd(A, B);
  A /= p, B /= p;
  int s = min(N / A, M / B);
  A *= s, B *= s;
  if (A > X * 2)
    CX = 0;
  else if (A > (N - X) * 2)
    CX = N - A;
  else
    CX = (X * 2 - A) / 2;
  if (B > Y * 2)
    CY = 0;
  else if (B > (M - Y) * 2)
    CY = M - B;
  else
    CY = (Y * 2 - B) / 2;
  printf("%d %d %d %d\n", CX, CY, CX + A, CY + B);
}
