#include <bits/stdc++.h>
using namespace std;
const int MAXN = 100010;
int v[MAXN];
set<int> st;
unordered_map<int, int> mp;
void insert(int x) {
  int oldv = mp[x]++;
  if (oldv == 1)
    st.erase(x);
  else if (oldv == 0)
    st.insert(x);
}
void rem(int x) {
  int oldv = mp[x]--;
  if (oldv == 1) mp.erase(x);
  if (oldv == 2)
    st.insert(x);
  else if (oldv == 1)
    st.erase(x);
}
int main() {
  ios::sync_with_stdio(false);
  int n, k;
  cin >> n >> k;
  for (int i = 0; i < (n); ++i) cin >> v[i];
  for (int i = 0; i < (k - 1); ++i) insert(v[i]);
  for (int i = k - 1; i < (n); ++i) {
    insert(v[i]);
    if (st.empty())
      cout << "Nothing\n";
    else
      cout << *st.rbegin() << endl;
    rem(v[i - k + 1]);
  }
  return 0;
}
