#include <bits/stdc++.h>
using namespace std;
long long t1, t2, x1, x2, t0;
long long delta(long long y1, long long y2) {
  if (y1 + y2 <= 0) return -1;
  return t1 * y1 + t2 * y2 - t0 * (y1 + y2);
}
int main() {
  cin >> t1 >> t2 >> x1 >> x2 >> t0;
  if (t1 == t2) {
    cout << x1 << " " << x2 << endl;
  } else if (t0 <= t1 && t0 <= t2) {
    if (t1 <= t2)
      cout << x1 << " " << 0 << endl;
    else
      cout << 0 << " " << x2 << endl;
  } else if (t0 >= t1 && t0 >= t2) {
    if (t1 >= t2)
      cout << x1 << " " << 0 << endl;
    else
      cout << 0 << " " << x2 << endl;
  } else {
    long long ans1 = -1, ans2 = -1, ans = -1;
    for (long long y1 = 0; y1 <= x1; y1++) {
      long long y2 = (t0 - t1) * y1 / (t2 - t0);
      if (y1 == 0) y2 = x2;
      if ((t2 - t0) * y2 < (t0 - t1) * y1) y2 += t2 - t0 > 0 ? 1 : -1;
      y2 = y2 > x2 ? x2 : y2 < 0 ? 0 : y2;
      if (delta(y1, y2) >= 0) {
        if (ans < 0 || delta(y1, y2) * (ans1 + ans2) < ans * (y1 + y2) ||
            (delta(y1, y2) * (ans1 + ans2) == ans * (y1 + y2) &&
             y1 + y2 > ans1 + ans2)) {
          ans = delta(y1, y2);
          ans1 = y1;
          ans2 = y2;
        }
      }
    }
    cout << ans1 << " " << ans2 << endl;
  }
}
