#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  int n, k;
  cin >> n >> k;
  k--;
  vector<long long> v(n);
  map<long long, int> vis, b;
  for (auto &i : v) {
    cin >> i;
  }
  for (int i = 0; i < n; i++) {
    vis[v[i]]++;
    if (vis[v[i]] > 1) {
      map<long long, int>::iterator j = b.find(v[i]);
      if (j != b.end()) {
        b.erase(j);
      }
    } else {
      b.insert({v[i], 1});
    }
    if (i >= k) {
      if (b.size() > 0) {
        map<long long, int>::iterator j = b.end();
        j--;
        cout << j->first << endl;
      } else {
        cout << "Nothing" << endl;
      }
      vis[v[i - k]]--;
      if (vis[v[i - k]] == 0) {
        b.erase(b.find(v[i - k]));
      } else if (vis[v[i - k]] == 1) {
        b.insert({v[i - k], 1});
      }
    }
  }
  return 0;
}
