#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
  int N,K;cin>>N>>K;
  ll A[N];
  for(int i=0;i<N;i++)cin>>A[i];
  for(int j=K;j<N;j++){
    if(A[j-K]<A[j])cout<<"Yes"<<endl;
    else cout<<"No"<<endl;
  }
}