#include <bits/stdc++.h>
using namespace std;
const int maxn = 100512, inf = 1e9;
pair<long long, long long> a[maxn];
int n, v;
long long f[maxn];
int main() {
  ios::sync_with_stdio(false);
  cin >> n;
  for (int i = 0; i < n; i++) cin >> a[i].first >> a[i].second;
  cin >> v;
  for (int i = 0; i < n; i++)
    a[i] = pair<long long, long long>(a[i].first + a[i].second * v,
                                      -a[i].first + a[i].second * v);
  a[n++] = pair<long long, long long>(0, 0);
  sort(a, a + n);
  memset(f, 0x3f, sizeof f);
  for (int i = n; i--;) {
    int p = upper_bound(f, f + n, -a[i].second) - f;
    if (a[i] == pair<long long, long long>(0, 0))
      cout << lower_bound(f, f + n, 0) - f << ' ';
    else
      f[p] = -a[i].second;
  }
  cout << lower_bound(f, f + n, inf) - f << endl;
  return 0;
}
