#include <bits/stdc++.h>
using namespace std;
int main() {
  double t1, t2;
  int n;
  double ma, mi;
  double k;
  cin >> n >> t1 >> t2 >> k;
  double p = k / 100;
  double arr[n];
  double check[n];
  double x, y;
  for (int i = 0; i < n; i++) {
    cin >> x >> y;
    double m = min(x, y);
    double m2 = m - (m * p);
    double l = max(x, y);
    double l2 = l - (l * p);
    double a = m2 * t1 + l * t2;
    double b = l2 * t1 + m * t2;
    arr[i] = max(a, b);
    check[i] = arr[i];
  }
  sort(arr, arr + n);
  for (int i = n; i >= 0; i--) {
    for (int j = 0; j < n; j++) {
      if (arr[i] == check[j]) {
        cout << j + 1 << " ";
        cout << fixed << setprecision(2) << arr[i] << endl;
        check[j] = -1;
        break;
      }
    }
  }
  return 0;
}
