#include <bits/stdc++.h>
using namespace std;
const long long inf = (1ll << 60);
long long C[500][500];
long long dp[500][500];
int main() {
  int n, m, k;
  while (~scanf("%d%d%d", &n, &m, &k)) {
    int l, r;
    long long c;
    for (int i = 0; i <= n + 1; ++i) {
      for (int j = 0; j <= n + 1; ++j) {
        dp[i][j] = inf;
        C[i][j] = inf;
      }
    }
    for (int i = 0; i <= n; ++i) dp[i][0] = 0;
    for (int i = 1; i <= m; ++i) {
      cin >> l >> r >> c;
      C[l][r] = min(C[l][r], c);
    }
    for (int i = 1; i <= n; ++i) {
      for (int j = n; j >= i; --j) {
        C[i][j] = min(C[i][j], C[i - 1][j]);
        C[i][j] = min(C[i][j], C[i][j + 1]);
      }
    }
    for (int i = 1; i <= n; ++i) {
      for (int j = 1; j <= i; ++j) {
        dp[i][j] = dp[i - 1][j];
        for (int p = 0; p < i; ++p) {
          if (C[p + 1][i] == inf) continue;
          dp[i][j] = min(dp[i][j], dp[p][j - i + p] + C[p + 1][i]);
        }
      }
    }
    long long ans = inf;
    for (int i = 1; i <= n; ++i)
      for (int j = k; j <= i; ++j) ans = min(ans, dp[i][j]);
    if (ans >= inf) ans = -1;
    cout << ans << endl;
  }
  return 0;
}
