#include <bits/stdc++.h>
using namespace std;
const int INF = (int)2e9 + 10;
const int mod = (int)1e9 + 7;
const int N = (int)1e6 + 10;
const long long LLINF = (long long)3e18 + 10;
const long double pi = acos(-1.0);
const long double eps = (long double)1e-7;
template <typename T1, typename T2>
bool umin(T1 &x, T2 y) {
  if (x > y) return x = y, true;
  return false;
}
template <typename T1, typename T2>
bool umax(T1 &x, T2 y) {
  if (x < y) return x = y, true;
  return false;
}
template <typename T>
T getint() {
  char c = getchar();
  T p = 1, x = 0;
  while (c == ' ' || c == '\n') c = getchar();
  if (c == '-') p = -1, c = getchar();
  while (c >= '0' && c <= '9') x = x * 10 + c - '0', c = getchar();
  return x * p;
}
long double sx, sy, sz, vx, vy, vz;
long double a, b, m;
bool flag;
void solve() {
  long double t = LLINF;
  if (vx > 0) umin(t, (a - sx) / vx);
  if (vx < 0) umin(t, (-sx) / vx);
  umin(t, (-sy) / vy);
  if (vz > 0) umin(t, (b - sz) / vz);
  if (vz < 0) umin(t, (-sz) / vz);
  sx = sx + vx * t;
  sy = sy + vy * t;
  sz = sz + vz * t;
  if (sy == 0) {
    flag = true;
    return;
  }
  if (sx == 0 || sx == a) vx *= -1;
  if (sz == 0 || sz == b) vz *= -1;
}
int main() {
  srand(time(NULL));
  ios_base::sync_with_stdio(0);
  cin >> a >> b >> m;
  cin >> vx >> vy >> vz;
  sx = a / 2;
  sy = m;
  sz = 0;
  while (!flag) {
    solve();
  }
  cout.precision(20);
  cout << sx << ' ' << sz << '\n';
  return 0;
}
