#include <bits/stdc++.h>   using namespace std;   int main() {     ios_base::sync_with_stdio(false);     cin.tie(NULL);     cout.tie(NULL);     int n, k, d;     cin >> n >> k >> d;     long long a[101], b[101];     memset(a, 0, sizeof(a));     memset(b, 0, sizeof(b));     a[0] = 1;     long long sum = 0;     for (int i = 0; i < k; i++) {       sum += a[i];       sum = (sum) % 1000000007;       a[i + 1] = sum;     }     for (int i = k; i < n; i++) {       sum += a[i];       sum -= a[i - k];       sum = ((sum % 1000000007) + 1000000007) % 1000000007;       a[i + 1] = sum;     }     for (int i = 1; i < d; i++) {       b[i] = 0;     }     b[d] = 1;     for (int i = d + 1; i <= k; i++) {       b[i] = b[i - 1] + b[i - 1] - b[i - d] + a[i - d];       b[i] = ((b[i] % 1000000007) + 1000000007) % 1000000007;     }     for (int i = k + 1; i <= n; i++) {       b[i] = b[i - 1] + b[i - 1] - b[i - d] + a[i - d] - a[i - k - 1];       b[i] = ((b[i] % 1000000007) + 1000000007) % 1000000007;     }     cout << b[n] << endl;   }   