#include <bits/stdc++.h>
int n, m, k;
int rows[1000];
int main() {
  int i, r, x;
  long long int sum = 0;
  scanf("%d%d%d", &n, &m, &k);
  for (i = 0; i < m; i++) rows[i] = 1000001;
  for (i = 0; i < n; i++) {
    scanf("%d%d", &r, &x);
    if (x < rows[r - 1]) rows[r - 1] = x;
  }
  for (i = 0; i < m; i++)
    if (rows[i] != 1000001) sum += rows[i];
  if (sum < k)
    printf("%lld\n", sum);
  else
    printf("%d\n", k);
  return 0;
}
