#include #define mp make_pair #define mt make_tuple #define pb push_back #define rep(i,n) for(int i=0;i<(n);i++) using namespace std; typedef long long ll; typedef unsigned long long ull; typedef pair pii; typedef pair pll; const int INF=1<<29; const double EPS=1e-9; const int MOD = 1000000007; const int dx[]={1,0,-1,0},dy[]={0,-1,0,1}; int N,S,K; int dp[110][20010]; int memo(int pos, int sum){ if (sum > S){ return 0; } if (pos == N - 1){ return 1; } if (dp[pos][sum] >= 0){ return dp[pos][sum]; } int res = 0; for (int i = 0; i*(N - pos) <= S; i++){ res += memo(pos + 1, sum + i * (N - pos)); res %= MOD; } return dp[pos][sum] = res; } int main(){ cin >> N >> S >> K; memset(dp, -1, sizeof(dp)); S -= N * (N - 1) / 2 * K; cout << memo(0, 0) << endl; return 0; }