#include #include using namespace std; using namespace atcoder; using ll = long long; using mint = modint1000000007; template vector> Partition(int N) { vector> r(N + 1, vector(101, 0)); for(int i = 0; i <= 100; i++) { r[0][i] = 1; } for(int i = 1; i <= N; i++) { for(int j = 1; j <= 100; j++) { r[i][j] = r[i][j - 1] + (i - j >= 0 ? r[i - j][j] : 0); } } return r; } int main() { ios::sync_with_stdio(false); cin.tie(nullptr); ll N, S, K; cin >> N >> S >> K; S -= K * N * (N - 1) / 2; if(S < 0) { cout << 0 << "\n"; return 0; } auto p = Partition(S); cout << p[S][N].val() << "\n"; }