#include using namespace std; int N,d,K; long long dp[90001][301]; long long const MOD = 1000000007; long long f(int x, int r) { if(dp[x][r] != -1) { return dp[x][r]; } else { long long ret = 0; for(int j=1; j<=d; ++j) { if(x - j < 0) break; ret = (ret + f(x - j, r - 1)) % MOD; } return dp[x][r] = ret; } } int main() { cin >> N >> d >> K; for(int i=0; i<90001; ++i) { for(int j=0; j<301; ++j) dp[i][j] = -1; } dp[0][0] = 1; for(int j=1; j<301; ++j) dp[0][j] = 0; for(int i=1; i<90001; ++i) dp[i][0] = 0; cout << f(K, N) << '\n'; }