#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i = 0; i < (int)n; i++)
using ll = long long;

int main(){
  ll n, p;
  cin >> n >> p;
  ll w[n], b[n], v[n];
  rep(i,n) cin >> w[i] >> b[i];
  ll sum = 0;
  rep(i,n) {
    w[i] *= (100-p);
    b[i] *= p;
    v[i] = w[i] + b[i];
    sum += b[i];
  }
  sort(v,v+n,greater<ll>());
  for(int i = 1; i < n; i++) v[i] += v[i-1];
  int ans = lower_bound(v,v+n,sum) - v;
  cout << ans+1 << endl;
}
