Codeforces Round 243 (Div. 1)
E
Sereja and Sets
Codeforces
2500
原题
← D→
翻译中…

Let's assume that set $*S*$ consists of $*m*$ distinct intervals $[*l*_{1}, *r*_{1}]$, $[*l*_{2}, *r*_{2}]$, $...$, $[*l*_{*m*}, *r*_{*m*}]$ ($1 ≤ *l*_{*i*} ≤ *r*_{*i*} ≤ *n*$; $*l*_{*i*}, *r*_{*i*}$ are integers).

翻译中…

Let's assume that $*f*(*S*)$ is the maximum number of intervals that you can choose from the set $*S*$, such that every two of them do not intersect. We assume that two intervals, $[*l*_{1}, *r*_{1}]$ and $[*l*_{2}, *r*_{2}]$, intersect if there is an integer $*x*$, which meets two inequalities: $*l*_{1} ≤ *x* ≤ *r*_{1}$ and $*l*_{2} ≤ *x* ≤ *r*_{2}$.

翻译中…

Sereja wonders, how many sets $*S*$ are there, such that $*f*(*S*) = *k*$? Count this number modulo $1000000007$ $(10^{9} + 7)$.

翻译中…

Input

翻译中…

The first line contains integers $*n*$, $*k*$ $(1 ≤ *n* ≤ 500; 0 ≤ *k* ≤ 500)$.

翻译中…

Output

翻译中…

In a single line, print the answer to the problem modulo $1000000007$ $(10^{9} + 7)$.

翻译中…

样例

Input #1
3 1
Output #1
23
InputCopy OutputCopy
Input #2
3 2
Output #2
32
InputCopy OutputCopy
Input #3
2 0
Output #3
1
InputCopy OutputCopy
Input #4
2 2
Output #4
2
InputCopy OutputCopy
题目信息
题号
425E
时间限制
1.5 s
内存限制
256 MB
标签
动态规划

题面与样例版权归 Codeforces 及出题人所有;中文翻译由 AI 生成(CI 管线),如有出入请以原文为准。