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>
 
using std::pair;
using std::vector;
using std::string;

typedef long long ll;
typedef pair<ll, ll> pll;
typedef pair<int, int> pii;
 
#define fst first
#define snd second
#define pb(a) push_back(a)
#define mp(a, b) std::make_pair(a, b)
#define debug(...) fprintf(stderr, __VA_ARGS__)
 
template <typename T> bool chkmax(T& a, T b) { return a < b ? a = b, 1 : 0; }
template <typename T> bool chkmin(T& a, T b) { return a > b ? a = b, 1 : 0; }
 
const int oo = 0x3f3f3f3f;
 
template<typename T> T read(T& x) {
    int f = 1; x = 0;
    char ch = getchar();
    for(;!isdigit(ch); ch = getchar()) if(ch == '-') f = -1;
    for(; isdigit(ch); ch = getchar()) x = x * 10 + ch - 48; 
    return x *= f;
}

const int mo = 1e9 + 7;

ll T, n, k;

int get_mnb(ll l, ll r) {
    int res = 0;
    for(int i = 60; i >= 0; --i) {
        if((l >> i & 1) == (r >> i & 1)) 
            res += (l >> i & 1);
        else {
            res += bool (l & ((1ll << i) - 1)); 
            break;
        }
    }
    return res;
}

vector<pll> temp;
std::map<vector<ll>, vector<pll>> mp;
std::map<vector<ll>, vector<pll>> :: iterator it;

void out (vector<ll> x) {
    for(auto v : x) printf("%lld ", v);
    printf("\n");
}
void out (vector<pll> x) {
    for(auto v : x) printf("(%lld, %lld) ", v.fst, v.snd);
    printf("\n");
}

void calc(int x, ll tims) {
    vector<ll> b;
    if(tims < 0) return;

    for(int i = 0; i < n; ++i) b.pb(temp[i].snd - (i <= x));
    
    std::sort(b.begin(), b.end());
    if(b[0] < 0) return;

    for(int i = n-1; i > 0; --i) { b[i] -= b[i-1]; }
    ll t = b[0]; b[0] = 0;

    tims = std::min(tims, t);
    mp[b].pb(mp(t - tims, t));
}

vector<ll> a;

int main() {

        read(n), read(k); 
        temp.resize(n), a.resize(n);

        for(int i = 0; i < n; ++i) read(a[i]);
        std::sort(a.begin(), a.end());

        mp.clear();

        for(int i = 0; i <= 60; ++i) {

            ll bits = (1ll << i) - 1;
            for(int j = 0; j < n; ++j) temp[j] = mp(a[j] & bits, a[j] >> i);

            std::sort(temp.begin(), temp.end());

            ll lst = 0;
            for(int j = 0, nxt = 0; j < n; j = nxt + 1) {
                nxt = j;
                while(nxt < n-1 && temp[nxt + 1].fst == temp[j].fst) ++ nxt;

                calc(j-1, k - i - get_mnb(lst, temp[j].fst));
                lst = temp[j].fst + 1;
            }
        }

        int ans = 0;
        for(it = mp.begin(); it != mp.end(); ++ it) {
            // out(it -> fst);
            // out(it -> snd);

            temp = it -> snd;
            std::sort(temp.begin(), temp.end());

            ll l = temp[0].fst, r = temp[0].snd;

            for(int i = 1; i < (int) temp.size(); ++i) {

                if(temp[i].fst <= r) {
                    chkmax(r, temp[i].snd);
                } else {
                    ans = (ans + (r - l + 1) % mo) % mo;
                    l = temp[i].fst;
                    r = temp[i].snd;
                }
            }
            ans = (ans + (r - l + 1) % mo) % mo;
        }
        printf("%d\n", ans);
    

    return 0;
}