#include <bits/stdc++.h>
using namespace std;
const int maxN = 1e5 + 9;
int x[maxN];
int v[maxN];
struct comp {
  int now = 0;
  bool operator()(int i, int j) {
    long long a = (long long)abs(x[i]) * abs(v[j] + now);
    long long b = (long long)abs(x[j]) * abs(v[i] + now);
    return a < b;
  }
};
int q[maxN];
int e[maxN];
int t[maxN];
int r[maxN];
long long d[maxN * 4];
void update(int i, int l, int r, int a) {
  if (l + 1 == r) {
    d[i]++;
  } else {
    int m = (l + r) / 2;
    if (a < m) {
      update(2 * i + 1, l, m, a);
    } else {
      update(2 * i + 2, m, r, a);
    }
    d[i] = d[2 * i + 1] + d[2 * i + 2];
  }
}
long long get(int i, int l, int r, int a, int b) {
  if (l >= b || r <= a) {
    return 0;
  }
  if (l >= a && r <= b) {
    return d[i];
  }
  int m = (l + r) / 2;
  long long q = get(2 * i + 1, l, m, a, b);
  long long w = get(2 * i + 2, m, r, a, b);
  return q + w;
}
int main() {
  int n, w;
  cin >> n >> w;
  for (int i = 0; i < n; i++) {
    cin >> x[i] >> v[i];
  }
  comp my_comp;
  for (int i = 0; i < n; i++) {
    q[i] = i;
    e[i] = i;
  }
  my_comp.now = -w;
  sort(q, q + n, my_comp);
  comp my_comp1;
  my_comp1.now = w;
  sort(e, e + n, my_comp1);
  int now = 0;
  t[q[0]] = 0;
  long long pre = 0;
  int len = 1;
  for (int i = 1; i < n; i++) {
    if (my_comp(q[i], q[i - 1]) || my_comp(q[i - 1], q[i])) {
      pre += (long long)len * (len - 1) / 2;
      len = 1;
      now++;
    } else {
      len++;
    }
    t[q[i]] = now;
  }
  pre += (long long)len * (len - 1) / 2;
  if (w == 0) {
    cout << pre << endl;
    return 0;
  }
  for (int i = 0; i < n; i++) {
    r[i] = t[e[i]];
  }
  long long ans = 0;
  int prev = 0;
  len = 1;
  long long prepre = 0;
  for (int i = 1; i < n; i++) {
    if (my_comp1(e[i], e[i - 1]) || my_comp1(e[i - 1], e[i])) {
      for (int j = prev; j < i; j++) {
        update(0, 0, n, r[j]);
      }
      prepre += (long long)len * (len - 1) / 2;
      len = 1;
      prev = i;
    } else {
      len++;
    }
    ans += get(0, 0, n, r[i] + 1, n);
  }
  prepre += (long long)len * (len - 1) / 2;
  cout << ans + pre + prepre << endl;
  return 0;
}
