// Last Update:2017-11-30 22:18:48
// author:sjy
#include<bits/stdc++.h>
using namespace std;
typedef long long LL;
LL w[100005],d[100005];
LL c[100005];
int main(void)
{
    int n,p;
    while(scanf("%d %d",&n,&p)!=EOF)
    {  LL sum = 0;
       for(int i = 0;i < n;i++)
           scanf("%lld %lld",&w[i],&d[i]),sum += w[i];
       LL k = p,kk = 100-p;
       sum = kk*sum;
       for(int i = 0;i < n;i++)
           c[i] = k*d[i] + kk*w[i];
       sort(c,c+n);
       int m = 0;
       for(int i = 0;i < n;i++)
       {
         if(sum >= c[i])
             sum -= c[i],m++;
         else break;
       }
       printf("%d\n",n - m);
    }
    return 0;
}