#include <bits/stdc++.h>
using namespace std;
int main() {
  int N, M, K, tot = 0, i;
  cin >> N >> M >> K;
  int arr[M + 1];
  memset(arr, 999999, sizeof(arr));
  for (i = 0; i < N; i++) {
    int ind, val;
    cin >> ind >> val;
    arr[ind] = min(val, arr[ind]);
  }
  for (i = 1; i <= M; i++) tot += arr[i];
  tot = min(tot, K);
  cout << tot;
  return 0;
}
