#include <bits/stdc++.h>
using namespace std;
struct point {
  int x, y;
  long long p, q;
  bool operator<(const point &o) const {
    return p < o.p || p == o.p && q > o.q;
  }
} p[100000];
long long l[100000];
int main() {
  int n;
  scanf("%d", &n);
  int a, b;
  scanf("%d/%d", &a, &b);
  int c, d;
  scanf("%d/%d", &c, &d);
  for (int i = 0; i < n; i++) {
    scanf("%d%d", &p[i].x, &p[i].y);
    p[i].p = (long long)b * p[i].y - (long long)a * p[i].x;
    p[i].q = (long long)c * p[i].x - (long long)d * p[i].y;
  }
  sort(p, p + n);
  int tot = 0;
  for (int i = 0; i < n; i++) {
    if (p[i].p <= 0 || p[i].q <= 0) continue;
    int loc = lower_bound(l, l + tot, p[i].q) - l;
    l[loc] = p[i].q;
    if (loc == tot) tot++;
  }
  printf("%d\n", tot);
  return 0;
}
