#include <bits/stdc++.h>
using namespace std;
char nxt[500], prv[500];
bool have[500];
int n;
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    string s;
    cin >> s;
    for (int j = 0; j < s.size(); j++) {
      have[s[j]] = 1;
      if (j) {
        prv[s[j]] = s[j - 1];
        nxt[s[j - 1]] = s[j];
      }
    }
  }
  for (char k = 'a'; k <= 'z'; k++) {
    if (have[k] && !prv[k]) {
      char y = k;
      while (y) {
        cout << y;
        y = nxt[y];
      }
    }
  }
  return 0;
}
