#include <bits/stdc++.h>
using namespace std;
struct water {
  int cold, hot;
} b[1000005];
int srt(water a, water b) {
  long long x, y;
  x = (long long)(a.hot) * (long long)(b.cold);
  y = (long long)(b.hot) * (long long)(a.cold);
  if (x == y) return (a.hot > b.hot);
  return (x < y);
}
int t1, t2, x1, x2, t0, i;
int main() {
  long long x;
  while (cin >> t1 >> t2 >> x1 >> x2 >> t0) {
    if (t1 == t2) {
      cout << x1 << ' ' << x2 << endl;
      continue;
    }
    if (t0 == t1) {
      cout << x1 << ' ' << 0 << endl;
      continue;
    }
    if (t0 == t2) {
      cout << 0 << ' ' << x2 << endl;
      continue;
    }
    for (i = 1, x = t2 - t0; i <= x2; i++) {
      x = (long long)(t2 - t0) * (long long)(i);
      x /= t0 - t1;
      b[i - 1].cold = min((long long)x1, x);
      b[i - 1].hot = i;
    }
    sort(b, b + x2, srt);
    cout << b[0].cold << ' ' << b[0].hot << endl;
  }
  return 0;
}
