#include <bits/stdc++.h>
using namespace std;
int i, j, k, m, n;
long long t1, t2, x1, x2, t0, a1, a2;
const double eps = 1e-10;
double ans = 1e100, ivs;
int main() {
  cin >> t1 >> t2 >> x1 >> x2 >> t0;
  if (t0 == t2) {
    if (t1 != t0) x1 = 0;
    cout << x1 << " " << x2 << endl;
    return 0;
  }
  if (t0 == t1) {
    x2 = 0;
    cout << x1 << " " << x2 << endl;
    return 0;
  }
  long long y2 = 1;
  a1 = 0;
  a2 = x2;
  ans = t2;
  for (long long y1 = 1; y1 <= x1; y1++) {
    while (y2 <= x2 && t1 * y1 + t2 * y2 < t0 * (y1 + y2)) y2++;
    if (y2 > x2) break;
    double t = 1.0 * (t1 * y1 + t2 * y2) / (y1 + y2);
    if (t > ans + eps) continue;
    if (t < ans - eps) {
      ans = t;
      a1 = y1;
      a2 = y2;
    } else {
      if (y1 + y2 > a1 + a2) {
        a1 = y1;
        a2 = y2;
      }
    }
  }
  cout << a1 << " " << a2 << endl;
  return 0;
}
