#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, k;
  cin >> n >> k;
  vector<long long> a(n);
  for (long long i = 0; i < (long long)n; ++i) {
    cin >> a[i];
  }
  map<long long, long long> mp;
  set<long long> st;
  for (long long i = 0; i < (long long)k; ++i) {
    mp[a[i]]++;
  }
  long long cur = -LLONG_MAX;
  for (auto e : mp) {
    if (e.second == 1) {
      st.insert(e.first);
      cur = max(cur, e.first);
    }
  }
  if (cur == -LLONG_MAX) {
    cout << "Nothing" << '\n';
  } else {
    cout << cur << '\n';
  }
  for (long long i = k; i < (long long)n; ++i) {
    mp[a[i - k]]--;
    if (mp[a[i - k]] == 0) {
      st.erase(st.find(a[i - k]));
    } else if (mp[a[i - k]] == 1) {
      st.insert(a[i - k]);
    }
    mp[a[i]]++;
    if (mp[a[i]] == 1) {
      st.insert(a[i]);
    } else if (mp[a[i]] == 2) {
      st.erase(st.find(a[i]));
    }
    auto it = st.rbegin();
    if (it != st.rend()) {
      cout << (*it) << '\n';
    } else {
      cout << "Nothing" << '\n';
    }
  }
  return 0;
}
