#include <bits/stdc++.h>
using namespace std;
signed long long int x, cost[305][305], dp[305][305];
int main() {
  int a, b, N, M, K;
  cin >> N >> M >> K;
  for (int i = 1; i <= N + 1; ++i)
    for (int j = 1; j <= N + 1; ++j)
      cost[i][j] = 100000000000000007LL, dp[i][j] = 100000000000000007LL;
  for (int i = 1; i <= M; ++i) {
    scanf("%d", &a);
    scanf("%d", &b);
    scanf("%d", &x);
    cost[a][b] = min(cost[a][b], x);
  }
  for (int i = 1; i <= N; ++i) {
    for (int j = i; j <= N; ++j) {
      for (int k = i; k <= j; ++k) {
        cost[k][j] = min(cost[k][j], cost[i][j]);
      }
    }
  }
  dp[N + 1][0] = 0;
  for (int i = N; i >= 1; i--) {
    for (int k = 1; k <= N; ++k) {
      dp[i][k] = dp[i + 1][k];
      for (int j = i; j <= N and k - (j - i + 1) >= 0; ++j) {
        dp[i][k] = min(dp[i][k], cost[i][j] + dp[j + 1][k - (j - i + 1)]);
      }
    }
  }
  signed long long int ans = 100000000000000007LL;
  for (int k = K; k <= N; ++k) ans = min(ans, dp[1][k]);
  if (ans == 100000000000000007LL)
    cout << -1;
  else
    cout << ans << endl;
}
