#include<cstdio>
#include<cstdlib>
#include<iostream>
using namespace std;
struct pos
{
long long q;
long long z;
}f[200000];
int main()
{
freopen("cowjoga.in","r",stdin);
freopen("cowjoga.out","w",stdout);
int n;
long long t;
scanf("%d%lld",&n,&t);
long long maxh=0;
int ans=1;
long long v;
for(int i=1;i<=n;++i)
{
scanf("%lld%lld",&f[i].q,&v);
f[i].z=(long long)(f[i].q+v*t);
}
long long now=f[n].z;
for(int i=n-1;i>=1;--i)
{
if(f[i].z<now)
{
now=f[i].z;
ans++;
}
}
printf("%d\n",ans);
return 0;
}