#include <bits/stdc++.h>
using namespace std;
long long cost[303][303], dp[303][303];
int main() {
  int n, m, k;
  cin >> n >> m >> k;
  memset(cost, 0x3f3f3f3f3f3f3f3f, sizeof(cost));
  for (int i = 1; i <= m; i++) {
    int l, r;
    long long c;
    cin >> l >> r >> c;
    for (int j = l; j <= r; j++) cost[l][j] = min(cost[l][j], c);
  }
  memset(dp, 0x3f3f3f3f3f3f3f3f, sizeof(dp));
  for (int i = 0; i <= n; i++) dp[i][0] = 0;
  for (int i = 1; i <= n; i++) {
    for (int j = 1; j <= i; j++) {
      dp[i][j] = dp[i - 1][j];
      for (int k = 1; k <= j; k++)
        dp[i][j] = min(dp[i][j], cost[i - k + 1][i] + dp[i - k][j - k]);
    }
  }
  long long result = 0x3f3f3f3f3f3f3f3f;
  for (int i = k; i <= n; i++) result = min(result, dp[n][i]);
  if (result < 0x3f3f3f3f3f3f3f3f)
    cout << result << "\n";
  else
    cout << "-1\n";
}
