#include <bits/stdc++.h>
using namespace std;
long long t1, t2, x1, x2, t0;
int eval(int y1, int y2) {
  if (y1 == 0 && y2 == 0) {
    return 0;
  }
  return ((long long)y1 * t1 + (long long)y2 * t2) / (y1 + y2);
}
int bin_search(int y1) {
  int front = 0, back = x2, y2 = -1;
  while (front <= back) {
    int mid = (front + back) / 2;
    if (eval(y1, mid) >= t0) {
      y2 = mid;
      back = mid - 1;
    } else {
      front = mid + 1;
    }
  }
  return y2;
}
int test(int best_y1, int best_y2, int y1, int y2) {
  if (best_y1 == 0 && best_y2 == 0) {
    return 1;
  }
  long long term1 = (t1 * y1 + t2 * y2) * (best_y1 + best_y2);
  long long term2 = (t1 * best_y1 + t2 * best_y2) * (y1 + y2);
  return term1 < term2 || (term1 == term2 && y1 + y2 > best_y1 + best_y2);
}
int main() {
  cin >> t1 >> t2 >> x1 >> x2 >> t0;
  if (t1 == t0 && t2 == t0) {
    cout << x1 << " " << x2 << endl;
    return 0;
  }
  long long best_y1 = 0, best_y2 = 0;
  for (int y1 = 0; y1 <= x1; ++y1) {
    int y2 = bin_search(y1);
    if (y1 == 0) {
      y2 = x2;
    }
    if (y2 != -1) {
      if (test(best_y1, best_y2, y1, y2)) {
        best_y1 = y1;
        best_y2 = y2;
      }
    }
  }
  cout << best_y1 << " " << best_y2 << endl;
  return 0;
}
