#include <bits/stdc++.h>
using namespace std;
int mn[1000005];
const int inf = 1000006;
int main() {
  int m, n, k;
  int row, v;
  while (cin >> n >> m >> k) {
    for (int i = 1; i <= m; i++) mn[i] = inf;
    for (int i = 0; i < n; i++) {
      scanf("%d%d", &row, &v);
      if (mn[row] > v) mn[row] = v;
    }
    int sum = 0;
    for (int i = 1; i <= m; i++) {
      if (mn[i] != inf) sum += mn[i];
      if (sum > k) break;
    }
    cout << min(sum, k) << endl;
  }
  return 0;
}
