Problem: There are N non-negative integers written on the blackboard: A_1, ..., A_N.

Snuke can perform the following two operations at most K times in total in any order:

* Operation A: Replace each integer X on the blackboard with X divided by 2, rounded down to the nearest integer.
* Operation B: Replace each integer X on the blackboard with X minus 1. This operation cannot be performed if one or more 0s are written on the blackboard.



Find the number of the different possible combinations of integers written on the blackboard after Snuke performs the operations, modulo 1,000,000,007.

Constraints

* 1 \leq N \leq 200
* 1 \leq A_i \leq 10^{18}
* 1 \leq K \leq 10^{18}
* A_i and K are integers.

Input

Input is given from Standard Input in the following format:


N K
A_1 A_2 ... A_N


Output

Print the number of the different possible combinations of integers written on the blackboard after Snuke performs the operations, modulo 1,000,000,007.

Examples

Input

2 2
5 7


Output

6


Input

3 4
10 13 22


Output

20


Input

1 100
10


Output

11


Input

10 123456789012345678
228344079825412349 478465001534875275 398048921164061989 329102208281783917 779698519704384319 617456682030809556 561259383338846380 254083246422083141 458181156833851984 502254767369499613


Output

164286011

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
#define ll long long
#define MOD 1000000007
#define u64 unsigned long long
using namespace std;
ll c[123][123];
void Ad(ll lim,int ty,ll sm[],int k)
{
	int bt=0;
	for(int i=k;i>=0;--i)
		if(lim>>i&1){
			for(int j=0;j<=i;j++)
				sm[bt+j]+=ty*c[i][j];
			++bt;
		}
	sm[bt]+=ty;
}
ll a[1234],cc[1234],d[1234];
ll tmp[64];
u64 gg=1234321237ll;
u64 Hsh(int n)
{
	u64 tmp=0;
	for(int i=2;i<=n;i++)
		tmp=tmp*gg+(u64)(cc[i]-cc[i-1]);
	return tmp;
}
unordered_map<u64,int> bok;
vector<pair<ll,ll>> sg[123456];
void solve()
{
	int n;
	ll kk;
	scanf("%d%lld",&n,&kk);
	for(int i=1;i<=n;i++)
		scanf("%lld",&a[i]);
	sort(a+1,a+n+1);
	int maxn=0;
	bok.clear();
	for(int k=0;k<=60;k++){
		for(int i=1;i<=n;i++)
			d[i]=a[i]%(1LL<<k);
		sort(d+1,d+n+1);
		d[0]=-1;
		d[n+1]=(1LL<<k)-1;
		for(int i=0;i<=n;i++){
			if(d[i]==d[i+1]||d[i]+1>a[1])continue;
			memset(tmp,0,sizeof(tmp));
			Ad(min(d[i+1],a[1]),1,tmp,k-1);
			if(i)Ad(d[i],-1,tmp,k-1);
			for(int j=1;j<=n;j++)
				cc[j]=(a[j]-d[i+1])>>k;
			u64 nv=Hsh(n);
			int id=bok[nv];
			if(!id){
				id=bok[nv]=++maxn;
				sg[maxn].clear();
			}
			for(int j=0;j<=k&&j+k<=kk;j++)
				if(tmp[j]){
					ll r=cc[1],l=max(r-(kk-j-k),0LL);
					sg[id].push_back(make_pair(l,r));
				}
		}
	}
	ll als=0;
	for(int i=1;i<=maxn;i++){
		sort(sg[i].begin(),sg[i].end());
		ll mx=-1,nl=0;
		for(pair<ll,ll>o:sg[i])
			if(o.first<=mx)mx=max(mx,o.second);
			else als+=(mx-nl+1)%MOD,mx=o.second,nl=o.first;
		als+=(mx-nl+1)%MOD;
	}
	printf("%lld\n",als%MOD);
}
int main()
{
	for(int i=0;i<=100;i++){
		c[i][0]=1;
		for(int j=1;j<=i;j++)
			c[i][j]=c[i-1][j-1]+c[i-1][j];
	}
	int t=1;
//	scanf("%d",&t);
	while(t--)solve();
	return 0;
}