#include<iostream>
#include<stack>
#include<cstring>
#include<cstdio>
#include<queue>
#include<vector>
#include<algorithm>
#define INF 0x3f3f3f3f
using namespace std; int a[]; int main(){
int n, m, k;
int ans, ret=;
scanf("%d%d%d", &n, &m, &k);
for(int i=; i<=m; ++i)
scanf("%d", &a[i]);
scanf("%d", &ans);
for(int i=; i<=m; ++i){
int tmp = ans^a[i], cnt=;
while(tmp){
if(tmp&) ++cnt;
tmp>>=;
}
if(cnt<=k) ++ret;
}
printf("%d\n", ret);
return ;
}
相关文章
- Codeforces 140A:New Year Table(数学几何&&精度)
- HDU 3435 A new Graph Game(二分图最优匹配:有向环覆盖)
- 【CodeForces】841D. Leha and another game about graph(Codeforces Round #429 (Div. 2))
- Codeforces Round #350 (Div. 2) B. Game of Robots __ interesting
- Codeforces Round #429 (Div. 2) - D Leha and another game about graph
- Codeforces Round #429 (Div. 2) D. Leha and another game about graph
- CodeForces 570B Simple Game 概率
- codeforces 497b// Tennis Game// Codeforces Round #283(Div. 1)
- Codeforces Round #346 (Div. 2)---E. New Reform--- 并查集(或连通图)
- Codeforces A. Game on Tree(期望dfs)