#include using namespace std; typedef long long ll; typedef pair pii; typedef pair pll; const int INF = 1e9; const int MOD = 1e9 + 7; int dp[110][20010] = {}; int main(){ int n, s, k; cin >> n >> s >> k; dp[0][0] = 1; for (int i = 1; i <= n; ++i) { for (int j = 0; j < s; ++j) { if(j - i >= 0) dp[i][j] = (dp[i][j-i] + dp[i-1][j]) % MOD; else dp[i][j] = dp[i-1][j]; } } for (int i = 0; i < n; ++i) { s -= i * k; } cout << dp[n][s] << endl; }