Ms. Evans has decided to spice up her daily commute by traveling to work on a pogo stick. The sidewalk on her path to work is composed of
Ms. Evans doesn't want to visit any tile more than once, since that would be boring. However, she enjoys jumping so much that she wants to make the maximum number of jumps possible. Please calculate the number of ways she can travel to work while fulfilling the above constraints. Since this number may be very large, you should output it modulo
Portion of marks | Constraints on | Constraints on |
---|---|---|
Input Specification
A single line containing
Output Specification
A single line containing the answer.
Sample Data
Input | Output |
---|---|
1 1 | 1 |
3 2 | 1 |
8 2 | 9 |
5 3 | 6 |
11 3 | 541 |
2015 2 | 166449575 |
Comments
This comment is hidden due to too much negative feedback. Show it anyway.