#include <bits/stdc++.h>
using namespace std;
void file_open() {
  freopen("test.txt", "rt", stdin);
  freopen("test.out", "wt", stdout);
}
int main() {
  long long t1, t2, x1, x2, t0, y1, y2, p1, p2;
  long long c1, c2, a, b;
  double t, r;
  scanf("%lld%lld%lld%lld%lld", &t1, &t2, &x1, &x2, &t0);
  c1 = t1 - t0;
  c2 = t2 - t0;
  y1 = y2 = 0;
  if (c1 == 0) y1 = x1;
  if (c2 == 0) y2 = x2;
  r = INT_MAX;
  if (c1 && c2) {
    if (c1 > 0) {
      c2 = -c2;
      for (int i = 1; i <= x1; ++i) {
        a = i;
        b = (a * c1) / (-c2);
        if (b > x2) b = x2;
        t = (a * t1 + b * t2) * 1.0 / (a + b);
        if (t >= t0 && t < r) {
          r = t;
          y1 = a;
          y2 = b;
        } else if (t == r && a + b > y1 + y2) {
          y1 = a;
          y2 = b;
        }
      }
    } else {
      c1 = -c1;
      for (int i = 1; i <= x2; ++i) {
        b = i;
        a = (b * c2) / c1;
        if (a > x1) a = x1;
        t = (a * t1 + b * t2) * 1.0 / (a + b);
        if (t >= t0 && t < r) {
          r = t;
          y1 = a;
          y2 = b;
        } else if (t == r && a + b > y1 + y2) {
          y1 = a;
          y2 = b;
        }
      }
    }
  }
  printf("%lld %lld", y1, y2);
  return 0;
}
