#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int n;
  string str;
  stack<string> chat;
  map<string, int> check;
  cin >> n;
  while (n--) {
    cin >> str;
    chat.push(str);
    check[str] = 1;
  }
  while (!chat.empty()) {
    if (check[chat.top()] == 1) cout << chat.top() << "\n";
    check[chat.top()] = 0;
    chat.pop();
  }
  return 0;
}
