#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, t1, t2;
  double k;
  cin >> n >> t1 >> t2 >> k;
  k /= 100.0;
  k = 1 - k;
  vector<pair<double, int> > res(n);
  for (int i = 0; i < n; i++) {
    int a, b;
    cin >> a >> b;
    res[i] = make_pair(-1.0 * max(1.0 * a * t1 * k + 1.0 * b * t2,
                                  1.0 * b * t1 * k + 1.0 * a * t2),
                       i + 1);
  }
  sort(res.begin(), res.end());
  cout.setf(ios::fixed);
  cout.precision(2);
  for (int i = 0; i < n; i++) {
    cout << res[i].second << " " << -res[i].first << endl;
  }
}
