#include<bits/stdc++.h>
using namespace std;
int main(){
	//write your code here......
	int n, m, x, a;
	map<int, int>map;
	cin>>n>>m;
	for(int i=0; i<n; i++){
		cin>>a;
		map[a]++;
	}
	while(m--){
		cin>>x;
		if(map.count(x)){
			 cout<<"yes"<<endl;
		}else{
			cout<<"no"<<endl;
		}
	}
	return 0;
}