#include <bits/stdc++.h>
using namespace std;
int main(void) {
  int n, m, k, r, c;
  cin >> n >> m >> k;
  vector<int> data(m, 1000000);
  for (int i = 0; i < n; ++i) {
    cin >> r >> c;
    data[r - 1] = min(data[r - 1], c);
  }
  cout << min(accumulate(data.begin(), data.end(), 0), k) << endl;
  return 0;
}
