#include <bits/stdc++.h>
using namespace std;
const int INF = 1 << 30;
long long t[1000];
int main() {
  int n, m, k;
  cin >> n >> m >> k;
  fill(t, t + m, INF);
  for (int i = 0; i < n; i++) {
    int r, c;
    cin >> r >> c;
    r--;
    t[r] = min(t[r], (long long)c);
  }
  long long res = 0LL;
  long long sum = accumulate(t, t + m, 0);
  res = min(sum, (long long)k);
  cout << res << endl;
  return 0;
}
