#include <bits/stdc++.h>
using namespace std;
const int INF = 1e9 + 7;
const int MOD = 1e9 + 7;
const int MAXN = 1e3 + 100;
const double eps = 1e-9;
int n;
int f[256], nxt[256], prv[256];
string s;
int main() {
  cout << setprecision(10) << fixed;
  scanf("%d", &n);
  for (int i = 1, _b = (n); i <= _b; i++) {
    cin >> s;
    for (int j = 0, _b = (s.size() - 1); j <= _b; j++) f[s[j]] = 1;
    for (int j = 1, _b = (s.size() - 1); j <= _b; j++)
      prv[s[j]] = 1, nxt[s[j - 1]] = s[j];
  }
  for (int i = 'a'; i <= 'z'; i++) {
    if (!prv[i] && f[i]) {
      int j = i;
      while (j) {
        cout << char(j);
        f[j] = 0;
        j = nxt[j];
      }
    }
  }
  return 0;
}
