#include <bits/stdc++.h>
using namespace std;
int grafo[20][20];
vector<int> sol;
bool assigned[20];
int N, k, t, peso = 0;
void findSol(int chi) {
  if (chi == N) {
    sol.push_back(peso);
    return;
  }
  findSol(chi + 1);
  for (int i = 0; i < N; i++)
    if (!assigned[i]) {
      assigned[i] = true;
      peso += grafo[chi][i];
      findSol(chi + 1);
      assigned[i] = false;
      peso -= grafo[chi][i];
    }
}
int main(void) {
  cin >> N >> k >> t;
  for (int i = 0; i < k; i++) {
    int da, a, x;
    cin >> da >> a >> x;
    da--;
    a--;
    grafo[da][a] = x;
  }
  findSol(0);
  sort(sol.begin(), sol.end());
  cout << sol[t - 1];
  return 0;
}
