#include <bits/stdc++.h>
using namespace std;
pair<long long, long long> a[10000007];
int main() {
  ios_base::sync_with_stdio(false);
  long long int n, i, mx, reqavg, ans = 0, sum = 0, shortage = 0, k = 0, t = 1,
                                  s = 0;
  cin >> n;
  cin >> mx >> reqavg;
  for (i = 1; i <= n; i++) {
    cin >> a[i].second;
    cin >> a[i].first;
    sum += a[i].second;
  }
  shortage = (n * reqavg) - sum;
  sort(a + 1, a + n + 1);
  i = 1;
  while (shortage > 0) {
    k = shortage;
    t = mx - a[i].second;
    if (t <= k) {
      ans += (t * a[i].first);
      shortage = shortage - t;
    } else {
      ans += (a[i].first * k);
      break;
    }
    i++;
  }
  cout << ans;
  return 0;
}
