#include <bits/stdc++.h>
#define REP(i,n,s) for (int i = (s); i < (n); i++)
#define MOD 1000000007;
using namespace std;
typedef long long int LL;

int N, K;
LL p[101], l[256][101];

int main() {
	ios::sync_with_stdio(0);
	cin.tie(0);

	cin >> N >> K;
	p[0] = 1;
	REP(i, N+1, 1) {
		p[i] = p[i-1]*i%MOD;
	}

	int a;
	LL tmp[256][101];
	REP(i, N, 0) {
		cin >> a;
		memset(tmp,0,sizeof(tmp));
		
		REP(j, 256, 0) {
			REP(k, 101, 0) {
				tmp[j][k] = (tmp[j][k]+l[j][k])%MOD;
				tmp[j^a][k+1] = (tmp[j^a][k+1]+l[j][k])%MOD;
			}
		}
		tmp[a][1]++;
		memcpy(l, tmp, sizeof(l));
	}
	LL res = 0;
	REP(i, 101, 1) {
		res = (res+p[i]*l[K][i])%MOD;
	}
	cout << res << endl;
}