#include <bits/stdc++.h>
using namespace std;
#pragma comment(linker, "/STACK:1608864")
void ASS(bool b) {
  if (!b) ++*(int*)0;
}
int main() {
  int n, m, k;
  scanf("%d %d %d", &n, &m, &k);
  const int inf = 1 << 30;
  vector<int> v(m, inf);
  for (int i = 0; i < (int)(n); i++) {
    int x, y;
    scanf("%d %d", &x, &y);
    x--;
    v[x] = min(v[x], y);
  }
  int res = 0;
  for (int i = 0; i < (int)(m); i++) res += v[i];
  res = min(res, k);
  printf("%d\n", res);
  return 0;
}
