#include #include #include #include #include #include #include #include #include #include #include using namespace std; typedef long long ll; typedef pair P; const ll mod = 1000000007; const int inf = 1e9; const long long INF = 1LL << 60; ll dp[310][90400]; int main() { int n,d,m; cin >> n >> d >> m; dp[0][0] = 1; for(int i = 0; i < n; i++){ for(int j = 0; j <= m; j++){ dp[i+1][j+1] += dp[i][j]; dp[i+1][j+1] %= mod; dp[i+1][j+1+d] -= dp[i][j]; dp[i+1][j+1+d] %= mod; } for(int j = 0; j <= m; j++){ dp[i+1][j+1] += dp[i+1][j]; dp[i][j] %= mod; } } cout << dp[n][m] % mod << endl; }