#include <bits/stdc++.h>
#pragma GCC optimize("O3")
using namespace std;
signed main() {
  long long a, b, m;
  cin >> a >> b >> m;
  double x, y, z;
  cin >> x >> y >> z;
  double absx = abs(x);
  double absy = abs(y);
  double absz = abs(z);
  double timey = m / absy;
  double resx = 0;
  if (x) {
    double timex = a / absx;
    double firstx = (a / 2.0) / absx;
    if (firstx >= timey) {
      resx = a / 2.0 + timey * x;
    } else {
      timey -= firstx;
      long long k = timey / (2 * timex);
      double kk = k * (2 * timex);
      if (x < 0) {
        if (timey - kk >= timex) {
          resx = a - absx * (timey - kk - timex);
        } else {
          resx = absx * (timey - kk);
        }
      } else {
        if (timey - kk >= timex) {
          resx = absx * (timey - kk - timex);
        } else {
          resx = a - absx * (timey - kk);
        }
      }
    }
  } else {
    resx = a / 2.0;
  }
  timey = m / absy;
  double resz = 0;
  if (z) {
    double timez = b / absz;
    if (timez >= timey) {
      resz = timey * z;
    } else {
      long long k = timey / (2.0 * timez);
      double kk = ((double)k) * (2.0 * timez);
      if (timey - kk >= timez) {
        resz = b - absz * (timey - kk - timez);
      } else {
        resz = absz * (timey - kk);
      }
    }
  } else {
    resz = 0;
  }
  printf("%.12lf", resx);
  ;
  cout << " ";
  printf("%.12lf", resz);
  ;
}
