#include <bits/stdc++.h>
using namespace std;
int n, k, t, a[21][21], match[21];
inline int count1(int n) {
  int ans = 0;
  for (; n > 0; n &= n - 1) ++ans;
  return ans;
}
void findAll(const vector<int> &males, vector<int> *ans, int k = 0, int w = 0) {
  if (k == males.size()) {
    ans->push_back(w);
    return;
  }
  for (int i = (0); i < (n); ++i)
    if (a[males[k]][i] > 0 && match[i] == -1) {
      match[i] = males[k];
      findAll(males, ans, k + 1, w + a[males[k]][i]);
      match[i] = -1;
    }
}
int main() {
  scanf("%d%d%d", &n, &k, &t);
  for (int i = (0); i < (k); ++i) {
    int u, v, r;
    scanf("%d%d%d", &u, &v, &r);
    --u, --v;
    a[u][v] = r;
  }
  vector<int> ans;
  for (int mask = 0; mask < (1 << n); ++mask) {
    vector<int> males;
    for (int i = (0); i < (n); ++i) {
      if (mask & (1 << i)) males.push_back(i);
    }
    memset(match, -1, sizeof match);
    findAll(males, &ans);
  }
  sort(ans.begin(), ans.end());
  printf("%d\n", ans[t - 1]);
  return 0;
}
