#include <bits/stdc++.h>
using namespace std;
set<long long> reco;
map<long long, int> a;
void vali() {
  long long ans = 0;
  if (reco.size() == 0) {
    printf("Nothing\n");
  } else {
    ans = *reco.rbegin();
    printf("%lld\n", ans);
  }
}
int main() {
  int n, k;
  deque<long long> dq;
  scanf("%d %d", &n, &k);
  for (int i = 0; i < n; i++) {
    long long inp;
    scanf("%lld", &inp);
    if (dq.size() == k) {
      vali();
      a[dq.front()]--;
      if (a[dq.front()] == 1) reco.insert(dq.front());
      if (a[dq.front()] == 0) {
        reco.erase(reco.find(dq.front()));
      }
      dq.pop_front();
    }
    dq.push_back(inp);
    a[inp]++;
    if (a[inp] <= 1) {
      reco.insert(inp);
    } else {
      if (reco.find(inp) != reco.end()) {
        reco.erase(reco.find(inp));
      }
    }
  }
  if (dq.size() == k) {
    vali();
  }
  return 0;
}
