#include <bits/stdc++.h>
using namespace std;
const int N = 305;
const long long INF = 1LL << 60;
long long dp[N][N];
long long cost[N][N];
int main() {
  int n, m, tar, l, r, c;
  scanf("%d%d%d", &n, &m, &tar);
  for (int i = 0; i <= n; i++) {
    fill(dp[i], dp[i] + n + 1, INF);
    fill(cost[i], cost[i] + n + 1, INF);
  }
  for (int i = 0; i < m; i++) {
    scanf("%d%d%d", &l, &r, &c);
    for (int j = l; j <= r; j++) cost[j][r] = min(cost[j][r], c + 0LL);
  }
  dp[0][0] = 0;
  for (int i = 1; i <= n; i++)
    for (int j = 0; j <= i; j++) {
      for (int k = j; k < i; k++) dp[i][j] = min(dp[i][j], dp[k][j]);
      for (int k = i - j + 1; k <= i; k++)
        dp[i][j] = min(dp[i][j], cost[k][i] + dp[k - 1][k - (i - j + 1)]);
    }
  if (dp[n][tar] == INF)
    puts("-1");
  else
    printf("%I64d\n", dp[n][tar]);
  return 0;
}
