#include #include using namespace std; const int MOD = (int)1e9+7; int dp[101][20001]; int main(void){ int N, S, K; cin >> N >> S >> K; // (S-NK)のN分割を求めれば良い。 int A = S - N * (N-1) * K / 2; if(A < 0){ cout << "0\n"; return 0; } dp[0][0] = 1; for(int i = 1; i <= N; i++){ for(int j = 0; j <= A; j++){ if(j >= i) dp[i][j] = (dp[i][j-i] + dp[i-1][j]) % MOD; else dp[i][j] = dp[i-1][j]; } } cout << dp[N][A] << '\n'; return 0; }