#include using namespace std; #define REP(i,a,n) for(int i=(a); i<(int)(n); i++) #define rep(i,n) REP(i,0,n) #define FOR(it,c) for(__typeof((c).begin()) it=(c).begin(); it!=(c).end(); ++it) #define ALLOF(c) (c).begin(), (c).end() typedef long long ll; typedef unsigned long long ull; static const long long mod = 1000000007; struct mint { long long x; mint(ll x = 0):x(x%mod) {} mint& operator+=(const mint a) { (x += a.x) %= mod; return *this; } mint& operator-=(const mint a) { (x += mod-a.x) %= mod; return *this; } mint& operator*=(const mint a) { (x *= a.x) %= mod; return *this; } mint operator+(const mint a) const { mint ret(*this); return ret += a; } mint operator-(const mint a) const { mint ret(*this); return ret -= a; } mint operator*(const mint a) const { mint ret(*this); return ret *= a; } mint pow(ll t) const { if(t==0) return mint(1); mint a = pow(t>>1); a *= a; if(t&1) a *= *this; return a; } //for prime mod mint inv() const { return pow(mod-2); } mint& operator/=(const mint a) { return (*this) *= a.inv(); } mint operator/(const mint a) const { mint ret(*this); return ret /= a; } }; ostream &operator<<(ostream& os, const mint& x) { os << x.x; return os; } mint dp[305][90005]; int main(){ int N, d, K; cin >> N >> d >> K; dp[0][0] = 1; rep(i,N){ vector imos(90005, 0); rep(j,90005){ int a = j+1; int b = j+d+1; if(a<90005) imos[a] += dp[i][j]; if(b<90005) imos[b] -= dp[i][j]; } mint base(0); rep(j,90005){ base += imos[j]; dp[i+1][j] = base; } } cout << dp[N][K] << endl; return 0; }