#include <bits/stdc++.h>
using namespace std;
int main() {
  int t1, t2, x1, x2, t;
  cin >> t1 >> t2 >> x1 >> x2 >> t;
  int cc, hh;
  if (t1 == t2 && t2 == t) {
    cout << x1 << " " << x2 << endl;
    return 0;
  }
  if (t1 == t) {
    cout << x1 << " " << 0 << endl;
    return 0;
  }
  if (t2 == t) {
    cout << 0 << " " << x2 << endl;
    return 0;
  }
  int maxstream = x2;
  cc = 0, hh = x2;
  for (int cold = 1; cold <= x1; cold++) {
    long long hot = ((long long)(t - t1) * cold + (t2 - t - 1)) / (t2 - t);
    if (hot <= x2) {
      long long left = ((long long)t1 * cc + (long long)t2 * hh) * (cold + hot);
      long long right =
          ((long long)t1 * cold + (long long)t2 * hot) * (cc + hh);
      if (left > right) {
        maxstream = cold + hot;
        cc = cold, hh = hot;
      } else if (left == right && cold + hot > maxstream) {
        maxstream = cold + hot;
        cc = cold, hh = hot;
      }
    }
  }
  cout << cc << " " << hh << endl;
  return 0;
}
