#include <bits/stdc++.h>
using namespace std;
const int INF = 1e9;
signed main() {
  ios_base::sync_with_stdio(0);
  int n, m, k;
  cin >> n >> m >> k;
  vector<int> ar(m, INF);
  for (int i = 0; i < n; ++i) {
    int r, c;
    cin >> r;
    cin >> c;
    --r;
    ar[r] = min(ar[r], c);
  }
  int mn = 0;
  for (int i = 0; i < m; ++i) {
    if (ar[i] != INF) mn += ar[i];
  }
  cout << min(mn, k);
}
