Problem: Niwango bought a piece of land that can be represented as a half-open interval [0, X).

Niwango will lay out N vinyl sheets on this land. The sheets are numbered 1,2, \ldots, N, and they are distinguishable. For Sheet i, he can choose an integer j such that 0 \leq j \leq X - L_i and cover [j, j + L_i) with this sheet.

Find the number of ways to cover the land with the sheets such that no point in [0, X) remains uncovered, modulo (10^9+7). We consider two ways to cover the land different if and only if there is an integer i (1 \leq i \leq N) such that the region covered by Sheet i is different.

Constraints

* 1 \leq N \leq 100
* 1 \leq L_i \leq X \leq 500
* All values in input are integers.

Input

Input is given from Standard Input in the following format:


N X
L_1 L_2 \ldots L_N


Output

Print the answer.

Examples

Input

3 3
1 1 2


Output

10


Input

18 477
324 31 27 227 9 21 41 29 50 34 2 362 92 11 13 17 183 119


Output

134796357

Solution (in CPP):

Solution:
#include<cstdio>
#include<cstring>
#include<cstdlib>
#include<algorithm>
#include<cmath>
#include<queue>
#include<vector>
#include<ctime>
#include<map>
#include<bitset>
#include<set>
#include<assert.h>
#define LL long long
#define mp(x,y) make_pair(x,y)
#define pll pair<long long,long long>
#define pii pair<int,int>
#define SZ(x) ((int)x.size())
using namespace std;
inline int read()
{
	int f=1,x=0;char ch=getchar();
	while(ch<'0'||ch>'9'){if(ch=='-')f=-1;ch=getchar();}
	while(ch>='0'&&ch<='9'){x=x*10+ch-'0';ch=getchar();}
	return x*f;
}
int stack[20];
template<typename T>inline void write(T x)
{
	if(x<0){putchar('-');x=-x;}
    if(!x){putchar('0');return;}
    int top=0;
    while(x)stack[++top]=x%10,x/=10;
    while(top)putchar(stack[top--]+'0');
}
template<typename T>inline void pr1(T x){write(x);putchar(' ');}
template<typename T>inline void pr2(T x){write(x);putchar('\n');}
const int MAXN=505;
const int mod=1e9+7;
int pow_mod(int a,int b)
{
	int ret=1;
	for(;b;b>>=1,a=1LL*a*a%mod)if(b&1)ret=1LL*ret*a%mod;
	return ret;
}
void ad(int &x,int y){x+=y;if(x>=mod)x-=mod;}
void dl(int &x,int y){x-=y;if(x<0)x+=mod;}
int f[MAXN][MAXN],g[MAXN][MAXN];
int n,X,num[MAXN],pw[MAXN][MAXN],C[MAXN][MAXN],inv[MAXN],pre[MAXN];
int main()
{
	for(int i=0;i<MAXN;i++)
	{
		C[i][0]=1;
		for(int j=1;j<=i;j++)C[i][j]=C[i-1][j],ad(C[i][j],C[i-1][j-1]);
	}
	for(int i=0;i<MAXN;i++)
	{
		pw[i][0]=1;
		for(int j=1;j<MAXN;j++)pw[i][j]=1LL*pw[i][j-1]*i%mod;
	}
	pre[0]=1;for(int i=1;i<MAXN;i++)pre[i]=1LL*pre[i-1]*i%mod;
	inv[MAXN-1]=pow_mod(pre[MAXN-1],mod-2);
	for(int i=MAXN-2;i>=0;i--)inv[i]=1LL*inv[i+1]*(i+1)%mod;
	n=read();X=read();
	for(int i=1;i<=n;i++)num[read()]++;
	f[0][0]=1;
	for(int i=X;i>=1;i--)
	{
		for(int j=0;2*j-1<=X;j++)for(int k=i*j;k+j-1<=X;k++)if(f[j][k])
			for(int l=0;k+l*i<=X&&2*(j+l)-1<=X;l++)
				ad(g[j+l][k+l*i],1LL*f[j][k]*inv[l]%mod);
		for(int j=0;2*j-1<=X;j++)for(int k=i*j;k<=X;k++)
		{
			f[j][k]=1LL*g[j][k]*pw[k-i*j+j][num[i]]%mod;
			g[j][k]=0;
		}
	}
	int ans=0;
	for(int i=0;2*i-1<=X;i++)for(int j=0;j+i-1<=X;j++)if(f[i][j])
	{
		int t=1LL*C[X-(j+i-1)+i][i]*f[i][j]%mod*pre[i]%mod;
		if((X-j)&1)dl(ans,t);else ad(ans,t);
	}pr2(ans);
	return 0;
}