#Lutece2786. 风中花

风中花

Migrated from Lutece 2786 风中花

All parts of this problem, including description, images, samples, data and checker, might be broken. If you find bugs in this problem, please contact the admins.

Description

翩然漫舞,梦的花朵。 随风荡漾。 渐渐飘散,渐渐迷漫,沉浸的梦。

风伴着花飘散。 总共有 nn 朵花飘扬。 而风会不断飘过一朵朵。 具体的,风会从第 ss 朵花出发,不重复的经过所有花,最后飘过第 tt 朵花。 而风是飘荡的。 即如果风从 prepre 飘过 nownow ,下一次飘过 nextnext。 如果 pre<nowpre<now,则 next<nownext<now。 如果 pre>nowpre>now,则 next>nownext>now。 梦会知道所有可能的风。即所有经过花的顺序不同的总方案数。 这个数可能会很大,所以你只需要知道方案数对 109+710^9+7 取模后的结果。

Input

一行三个整数 n,s,tn,s,t

Output

输出一个整数表示答案

Samples

4 2 3
2
6 3 4
8
191 98 10
547397774

Constraints

2n2×1032\le n \le 2\times 10^3 sts\not=t

Resources

2022 UESTC ICPC Training for Dynamic Programming