#d11101. 与

与

AND Operation Arrays

Problem Description

Given nn and kk. Count how many arrays a1,a2,…,aka_1, a_2, \dots, a_k of length kk satisfy:

  • ∑i=1kai=n\sum_{i=1}^k a_i = n, with ai≥0a_i \ge 0.
  • For every i=1,…,k−1i = 1, \dots, k-1, ai AND ai+1=ai+1a_i\ \mathrm{AND}\ a_{i+1} = a_{i+1}, where AND\mathrm{AND} denotes the bitwise AND operation.

Output the answer modulo 109+710^9 + 7.

Input Format

The first line contains two integers k,nk, n.

Output Format

One integer — the answer.

Sample Input 1

4 2

Sample Output 1

2

Sample Input 2

1919 810

Sample Output 2

501617298

Constraints

There are 10 test points in total.

  • Test points 1, 2 satisfy n,k≤10n, k \le 10.
  • Test points 3, 4 satisfy n,k≤100n, k \le 100.
  • Test points 5, 6 satisfy n,k≤1000n, k \le 1000.

For all data, 1≤n,k≤1041 \le n, k \le 10^4.