#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, k, a[1005], b[1005], i, j, c, r, s = 0;
  cin >> n >> m >> k;
  for (i = 1; i <= m; i++) {
    b[i] = 0;
  }
  for (i = 1; i <= n; i++) {
    cin >> r >> c;
    if (b[r] == 0) {
      b[r]++;
      a[r] = c;
    } else if (c < a[r]) {
      a[r] = c;
    }
  }
  for (i = 1; i <= m; i++) {
    s += a[i];
  }
  cout << min(k, s);
  return 0;
}
