#include <bits/stdc++.h>
using namespace std;
void precalc(){};
void solve(int ncase) {
  int n;
  cin >> n;
  const int N = 26;
  vector<int> indegree(N);
  vector<int> exist(N);
  vector<char> nextchar(N);
  for (int i = 0; i < n; i++) {
    string str;
    cin >> str;
    for (int j = 0; j < str.size(); j++) {
      exist[str[j] - 'a'] = 1;
      if (j > 0) {
        indegree[str[j] - 'a'] = 1;
        nextchar[str[j - 1] - 'a'] = str[j];
      }
    }
  }
  string ret;
  for (int i = 0; i < N; i++) {
    if (exist[i] && indegree[i] == 0) {
      char key = 'a' + i;
      do {
        ret += key;
        key = nextchar[key - 'a'];
      } while (key > 0);
    }
  }
  cout << ret << endl;
}
int main() {
  int T = 1;
  precalc();
  int ncase = 0;
  while (T--) {
    solve(++ncase);
  }
}
